How to display UIScrollView scrollbar/s permanently instead of just flashing? - ios

The app I am building for an iPad has multiple text fields. So I had to use a scrollview. I would like to display the scrollbar/s permanently so that the user knows there are some more fields at the bottom.

As far I'm aware, it's not possible to permanently show the scrollbar.
Apple recommends to flash the scrollbar using:
[theScrollView flashScrollIndicators];

Related

iOS custom keyboard on iPad

I'm building an iPad app witch will use a numeric keyboard. The numeric keyboard for the iPad is really huge, all i need is something smaller, something like the decimal keyboard for the iphone.
If i use the default one, half the screen gets covered with keys i dont need. I know i can move the textfields out of the way but it is such a waste of screen space.
So i tried building a custom UIView with no button for start and setting the textfield.inputview to my custom UIView.
The only thing i got is that my custom view is displayed like/in place of/the stock keyboard and the only thing i can change is the height of the custom view.
How could i build a sort of custom keyboard that apple will accept and works with the textfields.
Thank you.
I found what i was looking for. The answer is UIPopover. I managed to build a custom keypad inside a uipopover.
Here's a good tutorial for the uipopover:
http://www.appcoda.com/uiactionsheet-uipopovercontroller-tutorial/
And here's some more info on what you have to do to make it work:
http://iphone-bitcode.blogspot.fr/2011/12/custom-number-pad-on-ipad.html

iOS 7 Messages: Fixed UITableView while still being able to bring up textfield?

I've done a lot of research before asking this question and haven't found a thorough answer. Forgive me if it's been asked somewhere else. I have been working on a messaging app for a few weeks now. Taking into account a typical messaging app (text field at bottom for user input with a table to store messages, pictures etc.) I understand that when the keyboard is shown the whole view must be pushed up to get the UITextField above the keyboard to show user input. I examined the native messages app on iOS 7 however, and I noticed that when the keyboard is shown ONLY the UITextField is moved up from the bottom of the view and the table view stays fixed (at least that's how I believe they are doing it). I know the table stays at a fixed point because when you scroll down to older messages at the top of the table, the most recent messages can be seen blurred behind the keyboard and can go all the way down the view itself while still having the keyboard visible. My question here is: is it possible to have a fixed table view while still being able to bring the text field up above the keyboard to show user input? In other words, is it possible to move just the text field up without having to move the whole view itself up?
Why not set the inputAccessoryView of the original textfield to be another textfield?
self.textFieldAtBottomOfView.inputAccessoryView = [[UITextField alloc] initWithFrame:CGRectMake(0, 0, 250, 30)];
that way you'll get a textfield that floats above the keyboard. You might need to style it to look like your first textfield and the user would think that it moved up above the keyboard on focus.

Editing keyboard layout in iOS

Is there a possibility to change the button layout on a pre-made ios keyboard?
I would like to add "done" and "punctuation" buttons to numeric keyboard.
There is the Decimal Pad available but in this case i would have to add a custom done button at the top.
Is there a way to move the "delete" button to the right and make it half of its current width, put next to it the "decimal" button and on the former place of "delete" locate "done"?
No, you'll have to implement your own keyboard, if you duplicate the Apple one it will get rejected.
iOS does not support making those types of changes to the keyboard, the only thing you can do is change the text associated with the Done/Enter button by changing the UIReturnKeyType of the associated UITextField.
You can make a View With the buttons you want and set the inputView to the custom view you made ,, and you got a custom keyboard :D
You cannot directly modify the keyboard other than by choosing one of apple's presets. However, it is possible to add additional keys above it using -inputAccessoryView, like WolframAlpha has done in its app.
It looks like you can replace the keyboard entirely, but the accesory view is probably the way to go. See the answer to Adding key to IPad keyboard
EDIT: For an example of how this would look, check out WolframAlpha's blog post on the subject. In your case the accessory view probably won't be quite so tall

How can I add to the iOS VoiceOver rotor for a custom view?

Recently, I've been working to get my application functioning well with VoiceOver. Generally it's been simple and straightforward, but there are some behaviors from system apps that I'd like to emulate, and I'm having a hard time locating the API to set things up.
In particular, I'm interested in adding a couple of options to the VoiceOver "rotor" and responding to them when the user increases and decreases the value. However, despite the fact that apps like Apple's Maps app add items to the rotor and are able to respond, I can't figure out how to do so for my app.
Has anyone succeeded in doing this? And if so, how?
With iOS 8, you can use the -accessibilityCustomActions method to return an array of UIAccessibilityCustomAction objects, representing the actions you'd like to present "rotor-style".
UPDATE: iOS 10 finally adds ability to add custom rotor items to VoiceOver (not the same thing as the "Actions" rotor item) - just add array of UIAccessibilityCustomRotor objects to accessibilityCustomRotors of the appropriate container view.
OLD ANSWER:
There is currently no API to add your own rotor items. You can only implement how some of the existing rotor items work:
"Adjust value" - here you should return UIAccessibilityTraitAdjustable trait for accessibilityTraits and then implement the accessibilityIncrement/accessibilityDecrement methods
"Headings" - you mark some views as UIAccessibilityTraitHeader, then those should be the view the user moves through when the user rotates to "Headings" and flicks up/down
OLD UPDATE: "Actions" - see UIAccessibilityCustomAction
I guess you should file a radar if you need to add custom items to rotor.

Unable to implement UISlider for Accessibility option in iPad

i am trying to implement accessibility option in my book reader app. I have a slider(similar to ibooks) which is used for navigating between pages. i have seen this question posted by another user and implemented the same code in my app. Right now my slider is responding when i'm tapping on it. The voiceover is also speaking the label i have given in the code. But, the problem is that, i am unable to change the slider value and navigate to another page.. I dont know if it is the problem with my code or is it that i do not know how to replicate the gesture to change the value of the slider... Any help in this regard will be appreciated.... Thanku
Does the slider work with VoiceOver turned off?
If so, try swiping vertically up or down (top to bottom of display) after selecting the slider element with VoiceOver enabled.
Is it a UISlider, or something of your own devising? UISlider needs an actual vertical swipe once selected, and moves a pretty significant amount as a result — not a good experience for going to the next page.
If it's your own custom control, be sure you set UIAccessibilityTraitAdjustable.

Resources