Home » Developing U++ » U++ Developers corner » Trouble with SizePos...
Trouble with SizePos... [message #34517] |
Sat, 26 November 2011 17:13 |
|
mirek
Messages: 14112 Registered: November 2005
|
Ultimate Member |
|
|
One of expected features of U++ web framework (I guess, we need a name for it, W++ is stupid, but will do for now) is possibility to design forms in Layout designer.
There, I can do LeftPos / RightPos (and Top,Bottom) equivalents easily:
<input type="text" style="width:40em;position:absolute;left:20em;top:20em" name="firstname" />
<input type="text" style="width:40em;position:absolute;right:20em;top:20em" name="firstname" />
but it is not possible to do SizePos this way (it can be either left or right, not both).
I have tried doing this with margins, but problem there is that in that case, html layout engine does not allow me to "overlap" widgets (so I cannot e.g. place label in the margin area).
Do I have to do this in JavaScript (and how?), or there is some other possiblity?
Note that the result should be compatible with U++ layouts...
Mirek
|
|
|
Re: Trouble with SizePos... [message #34520 is a reply to message #34517] |
Sat, 26 November 2011 18:37 |
|
This works fine for me (in chromium 17):
<span style="position:absolute;">label</span>
<input type="text" style="position:absolute;margin-left:10em;left:0;right:0;" name="firstname" />
If it causes some problems in other browsers, possible workaround might be to use layers ("z-index" in CSS), butit should not be necessary.
Honza
PS: Actually, specifying both left and right seems to work too:<span style="position:absolute;">label</span>
<input type="text" style="position:absolute;left:10em;right:0;" name="firstname" />
[Updated on: Sat, 26 November 2011 18:44] Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Sun Nov 10 20:18:12 CET 2024
Total time taken to generate the page: 0.00923 seconds
|