ios - How to offset the title control in Titanium -
how offset title control in titanium?
right trying put left: -100 property on label in title control , works when open view moves center.
are there suggestions on how can achieve move over?
thanks in advance!
var txtsearch = titanium.ui.createtextfield({ hinttext: 'keyword search for', height: 'auto', width: 220, left: -100, font: {fontsize: 12}, enabled: true, keyboardtype:titanium.ui.keyboard_email, returnkeytype:titanium.ui.returnkey_default, borderstyle:titanium.ui.input_borderstyle_rounded, autocapitalization: titanium.ui.text_autocapitalization_none, clearbuttonmode: titanium.ui.input_buttonmode_onfocus }); win.settitlecontrol(txtsearch); var btnsearch = titanium.ui.createbutton({ title: 'search', height: 'auto', width: 'auto', font: {fontsize: 13} }); win.rightnavbutton = btnsearch;
if click search button , brings me search results page , hit button textbox not moved on , looks fine.. when page first loads
try adding text field view, setting view title control:
var container = ti.ui.createview({ width: 320 }); var txtsearch = titanium.ui.createtextfield({ hinttext: 'keyword search for', height: 'auto', width: 220, left: 0, font: {fontsize: 12}, enabled: true, keyboardtype:titanium.ui.keyboard_email, returnkeytype:titanium.ui.returnkey_default, borderstyle:titanium.ui.input_borderstyle_rounded, autocapitalization: titanium.ui.text_autocapitalization_none, clearbuttonmode: titanium.ui.input_buttonmode_onfocus }); container.add(txtsearch); win.settitlecontrol(container);
Comments
Post a Comment