x


iOS :: increase slider thumb touch area

hi there!

how could I increase the touch area of a scroller thumb on iOS devices, esp. for iPhone 4. the touch area here is a really tiny one...

thnx!

more ▼

asked Nov 22 at 12:38 PM

headkit 1\'s gravatar image

headkit 1
181 28 37 45

(comments are locked)
10|3000 characters needed characters left
 moderation talk

1 answer:

I just came across the same issue, and I did a couple things which got it working:

  1. Make a new PNG bitmap for the horizontal slider...but have it mostly be empty space. For example, I made a 512x512 bitmap that has an 84 px thick line in the center, and the rest is just unused space (not black pixels). You can use The Gimp or Photoshop to get the job done.
  2. Make a new bitmap for the horizontal slider thumb. I just rendered a circle in my case. Unlike the bitmap in step 1, you don't need to make the image size much bigger than the visible shape.
  3. In Unity, make a new skin, and assign the bitmap from step 1 to Horizontal Slider -> Normal -> Background. Then assign the bitmap from step 2 to Horizontal Slider Thumb -> Normal -> Background.
  4. Play with the padding, margin, and overflow of both the slider and the thumb until they look good. The nice thing is you can do that while the simulation is running by using the mouse as your "test touch device". If you can move the slider thumb while clicking well above and below the visible horizontal slider, then you're golden.

I'm open to a better solution if anyone has any, though!

more ▼

answered Jan 25 at 03:16 AM

Gamieon\'s gravatar image

Gamieon
1

(comments are locked)
10|3000 characters needed characters left
 moderation talk
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x995
x325
x35
x4

Asked: Nov 22 at 12:38 PM

Seen: 460 times

Last Updated: Nov 22 at 12:38 PM

powered by Qato - Enterprise Q&A