| View previous topic :: View next topic |
| Author |
Message |
beardboy
Joined: 02 Mar 2004 Posts: 444 Location: SLC, Utah
|
Posted: Mon Mar 08, 2004 6:36 am Post subject: InputBox |
|
|
Input boxes only have the ability to have 6 lines. Would be nice if it would continue to stretch like message boxes.
thanks,
beardboy |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10463
|
Posted: Mon Mar 08, 2004 2:23 pm Post subject: |
|
|
That's a good one, thanks. Originally, I tried to make the InputBox as much like AutoIt v2's as I could, so that v2 scripts would run closer to how v2 runs them.
For improving a command like this without breaking existing scripts, one of my ideas is to have some special variables, that if defined in the script, change the default behavior of InputBox. For example:
A_InputBoxHeight = 600
Your idea is even better: that the box adjust to how much text you put in it. This is harder to implement for a GUI novice such as myself, because it probably requires font calculations, detection of word-wrap, newlines, etc. There's probably some open source code out there somewhere that creates the dialog at the right size to handle the specified text (I don't think v3 does this, though its InputBox is resizable by the user).
I want to implement at least one of these ideas eventually (perhaps someone will beat me to it).
Edit: If it's something you have an immediate use for, and if you just want the box to be wider or taller, I can probably do the variable-technique mentioned above fairly soon.
Edit #2: I just realized that InputBox is one of the commands that can have new parameters added to it without breaking existing scripts. So the size idea is even easier. I'll try to get this into the next release. |
|
| Back to top |
|
 |
beardboy
Joined: 02 Mar 2004 Posts: 444 Location: SLC, Utah
|
Posted: Sun Apr 04, 2004 6:38 pm Post subject: |
|
|
With the ability to resize the InputBox, I noticed that the OK and Cancel buttons aren't centered and the same size like other Message Boxes. Low priority but if you can make them standard size and centered like the other message box windows it would allow me to setup smaller Input Boxes without the ok button going off the left side of the window. Also the font size of the InputBox is a little bigger than the other message boxes.
thanks,
beardboy |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10463
|
Posted: Sun Apr 04, 2004 6:55 pm Post subject: |
|
|
I made the Cancel button smaller because I thought that the OK button, being more frequently pressed, should be more prominent and thus easier to click on. Maybe not the best decision... but I'm a little reluctant to change it since it's possible (though unlikely) that some scripts rely on the current size and relative positions of the buttons for mouse clicking. You could argue that they should not rely on it, now that the box is drag-resizable.
I think your idea for a font size option is a good one. I will also try to improve the centering of the Cancel button. |
|
| Back to top |
|
 |
beardboy
Joined: 02 Mar 2004 Posts: 444 Location: SLC, Utah
|
Posted: Sun Apr 04, 2004 10:07 pm Post subject: |
|
|
For those people that could be using the size and relative positions of the buttons, you could always leave the OK and Cancel buttons the way they are if no width or height is specified. That way if the default InputBox is brought up their mouse clicks would still work. If a width and height is specified it would use the standard sized buttons and center them together in the middle of the dialog box.
thanks,
beardboy |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10463
|
Posted: Sun Apr 04, 2004 10:40 pm Post subject: |
|
|
| Ok sounds good. I don't know if there's such a thing as a standard button size. It's even possible that MsgBox's button size varies depending on screen resolution and OS. But I will measure and apply. I think symmetry is best. |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10463
|
Posted: Sat Apr 17, 2004 3:06 pm Post subject: |
|
|
I forgot to fix the InputBox (as described above) in the last release. I've now made the button sizes both the same size (fairly small so that the window can be made small) and centered them.
I've changed the Installer. Feel free to re-download and re-install if you want the change right away.
The next change log entry will include:
Changed InputBox so that the buttons are the same size, which makes the window resize more evenly. [thanks beardboy & Rajat]
Does anyone still want the ability to change the font size? |
|
| Back to top |
|
 |
Rajat
Joined: 28 Mar 2004 Posts: 1717
|
Posted: Sun Apr 18, 2004 12:02 am Post subject: |
|
|
ah...now it looks nice. try this cute li'l thing:
InputBox, input, Enter Something,,, 130, 90
(i don't need font size change... don't know about others) _________________
 |
|
| Back to top |
|
 |
beardboy
Joined: 02 Mar 2004 Posts: 444 Location: SLC, Utah
|
Posted: Sun Apr 18, 2004 12:11 am Post subject: |
|
|
Perfect InputBox.
I don't need the font change, back when I posted the message about it I just noticed the font size was bigger than Message Boxes, and was bigger than AutoIt Input Boxes.
thanks,
beardboy |
|
| Back to top |
|
 |
|