marquee like UITextField - swift

How to create marquee like UITextField in Swift. I want to use it in a iOS controller where the user can click on the textfield and select a location, the text is longer enough that I need to implement the marquee Textfield, The text should scroll from right to left.

Related

Swift iOS 8+ UISearchBar icon, placeholder, and text centered

By default, the placeholder and icon of UISearchBar are left aligned. I want them to be centered like so:
On click of the search bar, the search text should also be centered.
I don't want to use offset because the alignment should dynamically change based on the length of the search text and the width of the phone. For example, if the UISearchBar has been clicked but no text is entered, the icon should right be in the middle.
Is there any solution - preferably not using offset - to center the search bar icon, search text, and placeholder?
Thank you
Don't use a UISearchBar, in the context of these kinds of customisations. You'll have to make your own using a UITextField and a UIImageView, and responding to the delegate calls.

Swift: How to "append" image to my text in uitextfield

I would like to append an image to my text in uitextfield, and since the text in the textfield is never consistent I cannot use rightview. Any suggestions?
P/S: I used a textfield instead of label because tapping the textfield is supposed to trigger a picker view.
Ahh, after scratching my head for the entire day, I ended up hide the text in my text field and add a uiLabel on top and an imageview beside it with autolayout and update the text.

create uitextfield over uiwebview textfield programmatically in iphone

I want to create uiTextField overlay on uiWebview and it is on the same position on the uiwebview input field.
i.e.: when user clicks on the textfield available on webview then new UITextfield is created and displayed over html textfield. when Editing is done uitextfield disappears then value is placed inside the textfield inside webview.
My application is in Phonegap architecture. please provide any suggestion or examples.
Thanks...
take one view, set background to clearColor & put textField inside it, show dynamically when you clicks your webView TextField. because of clearColor it feels like it is on webView

Adding smilies in Custom Keyboard

I want to add the smilies in the keyboard for text to add the comment like :P and <3 and if I did so to create the custom keyboard, will Apple reject my application?
You can add simple UIView with buttons above the keyboard, and show this view when keyboard appears. By pressing buttons just insert corresponding smiles to text.
if you are using something like UITextField, you can simply create a UIView with buttons like ":P",and assign this view to UITextField's inputAccessoryView property.

Iphone custom cell keyboard overlaps

i have a TableView with custom cells that i have built with Interface Builder.
Inside the cell, i have a label and a text field. But when i click on the text field to write, the keyboard overlaps the text field and i can't see what i am writing.
How can i avoid this?
Thanks
You have to resize the view containing the tableview when keyboard is shown. The way you can do is discussed here,
How to make a UITextField move up when keyboard is present?
You can search in Stackoverflow more on 'iphone keyboard hides textview'.
after resizing view, you can scroll table to the current cell too.