LoginSignup
4

More than 5 years have passed since last update.

9patchでStretchable Areaを横2箇所設置時に同幅にスケールしない問題の解決方法

Posted at

hukidashi_bg_n.9.png

ふきだしのしっぽ をセンターに表示したい場合など、左右の2箇所でスケールしたい時があります。
2箇所Stretchable Areaを設定した画像で、センター部分が右に寄ってしまうという現象が発生しました。
確認したのは、Galaxy S (OS:4.2.2) です。

解決方法:
根本的な原因は不明ですが、2箇所Stretchable Areaを設定した画像の横ピクセル数を
奇数にしたら直りました。
複数解像度に対応する場合は、画像を確認しないといけないので、めんどうですね...

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4