Cleanup key drawing code

This change also modifies 9-patch drawables to fix the following
issues.  In order to draw key background drawable just on the
coordinates we want, we have to know where an actual "visible" part is
in the drawable.  The only clue we can use is "padding" of the
drawable.  To achieve this, the 9-patch drawable must have its
"visible" part marked as "content".  Please refer the Bug: 4948171 for
more detailed explanation.

This change also reverts the following "black" drawables back from
Gingerbread because recent change broke these (I70019a91).
  * drawable-hdpi/sym_bkeyboard_*.png
  * drawable-hdpi/btn_keyboard_key_*_stone.9.png

Bug: 4948171
Change-Id: I6e4d03b3144caa95c793aac97af22df34c5f454f
diff --git a/java/res/values/attrs.xml b/java/res/values/attrs.xml
index 4470d7b..c5897c8 100644
--- a/java/res/values/attrs.xml
+++ b/java/res/values/attrs.xml
@@ -51,6 +51,12 @@
         <attr name="keyHintLabelRatio" format="float" />
         <!-- Size of the text for upper case letter, in the proportion of key height. -->
         <attr name="keyUppercaseLetterRatio" format="float" />
+        <!-- Horizontal padding of left/right aligned key label to the edge of the key. -->
+        <attr name="keyLabelHorizontalPadding" format="dimension" />
+        <!-- Top and right padding of hint letter to the edge of the key.-->
+        <attr name="keyHintLetterPadding" format="dimension" />
+        <!-- Top and right padding of upper case letter to the edge of the key.-->
+        <attr name="keyUppercaseLetterPadding" format="dimension" />
 
         <!-- Color to use for the label in a key. -->
         <attr name="keyTextColor" format="color" />
@@ -199,7 +205,6 @@
             <!-- This should be aligned with Key.LABEL_OPTION_* -->
             <flag name="alignLeft" value="0x01" />
             <flag name="alignRight" value="0x02" />
-            <flag name="alignBottom" value="0x04" />
             <flag name="alignLeftOfCenter" value="0x08" />
             <flag name="largeLetter" value="0x10" />
             <flag name="fontNormal" value="0x20" />