mIRC Home    About    Download    Register    News    Help

Print Thread
alt + * #178919 16/06/07 01:18 PM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
Is there a good reason that we can't press some alt + * when a dialog is the active window ?
With @win, we can, i think it will be great to can with dialog too


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #178943 16/06/07 06:12 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
What would that be for? You can use ALT and another key to activate a control if you set the control up properly (using &).


Invision Support
#Invision on irc.irchighway.net
Re: alt + * [Re: Riamus2] #178952 16/06/07 08:16 PM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
i'm not sure to understand what you said, did you said that we can 'set' what alt + another key will do on a dialog ?


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #178959 16/06/07 08:49 PM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
Yes. You put the & symbol before a letter in the caption of a button, and then hitting Alt+that letter will activate that button.

So making a button with the caption of "&Caption" would let you use Alt+C to access the button.

If you don't want a button but just want the key to do something, then simply adjust the button's position until it's off the dialog.

Re: alt + * [Re: hixxy] #178965 16/06/07 09:00 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
Originally Posted By: hixxy
If you don't want a button but just want the key to do something, then simply adjust the button's position until it's off the dialog.


Personally, I prefer to hide a button in that situation instead of placing it off of the dialog. It just seems cleaner that way. smile

Anyhow, here's an example part of a dialog:

Code:
  button "&Ok",20 20 20 10, ok


That will allow you to press Alt-O inside the dialog to activate the button.

Here's one more example:

Code:
  button "Open &Log",20 20 20 10


That will use Alt-L to activate the button. The & can be placed before any letter in the text.


Invision Support
#Invision on irc.irchighway.net
Re: alt + * [Re: Riamus2] #178976 16/06/07 09:45 PM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Just make sure that you don't specify the same letter in more than one button, otherwise it's going to default to the first one encountered in the dialog layout.

Re: alt + * [Re: hixxy] #178989 16/06/07 10:53 PM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
Ok i already know that, just forgotten works with alt because never use it.Anyway, i think if mirc can know if there a key for a letter and if not, apply what he doing with other active window like open mirc option when hit alt + o would be nice.


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #178994 16/06/07 11:26 PM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
As stated, just include the & in front of the key letter that you want to use. Windows (not mIRC) will track and alter the response as appropriate.

Re: alt + * [Re: RusselB] #178997 17/06/07 12:05 AM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
??
i don't want put & anywhere, i just want that if i hit alt + o on a dialog that haven't key letter for "o", mirc open mirc option




Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #178998 17/06/07 12:10 AM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
I can kind of see how it might be useful to allow Alt-O to open mIRC's options dialog even if you are in a dialog window as long as there isn't a &O somewhere in there, but I'm not sure how useful it really is. There are the occasional times when I try Alt-O while inside a dialog only to have nothing happen and I have to click out of the dialog, but it's pretty rare.


Invision Support
#Invision on irc.irchighway.net
Re: alt + * [Re: Riamus2] #179004 17/06/07 12:43 AM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
Yeah, for alt + o it isn't really useful but i wanted this option for alt + r, because as you said, click out of the dialog just to open mirc script editor ( thing that happen really often ) is a bit annoying to me


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #179007 17/06/07 01:50 AM
Joined: Aug 2004
Posts: 7,252
R
RusselB Offline
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
I think part of the reason for that might be to ensure that you don't edit the layout of a dialog while the dialog is open, since the layout in the code might've changed, but those changes wouldn't be reflected in the actual display until the dialog needed to be reopened, and, therefore, have to have been closed previously.

Re: alt + * [Re: RusselB] #179009 17/06/07 02:41 AM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
No, RussellB, that most likely doesn't have anything to do with it. Keep in mind that it is very useful to leave a dialog open and edit the events then test them rather than having to reopen the dialog every time. Events work immediately in a dialog once the script is saved. The only things that won't work without reopening the dialog are the default layout and the initialization code.

Most likely, the cause is just a matter of the default Alt commands only working when the main window is active as just a global way to prevent those from working if mIRC is minimized. Most likely, it just wasn't thought about needing to use those commands while in dialogs.


Invision Support
#Invision on irc.irchighway.net
Re: alt + * [Re: Riamus2] #179012 17/06/07 03:46 AM
Joined: Jul 2006
Posts: 3,568
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 3,568
Yes the exemple of editing remote and just saving code instead of reopening dialog is the best but you can imagine a dialog, with a button "open mirc option" or "open mirc script editor", and using com object, reproduce alt + 'o' or 'r' to do what you want.


Looking for a good help channel about mIRC? Check #mircscripting @ irc.swiftirc.net
Re: alt + * [Re: Wims] #179013 17/06/07 04:01 AM
Joined: Jul 2003
Posts: 655
Om3n Offline
Fjord artisan
Offline
Fjord artisan
Joined: Jul 2003
Posts: 655
To clarify Wims original post since it caused a little confusion.

Wims is requesting that when an alt key combination is not assigned in a dialog using &X, mirc should fall back on its own default alt key combinations rather than doing nothing.

This could be quite useful. Possibly confusing if you are not expecting a dialog to have a certain key conbination, yet it does and performs the wrong action, but useful non-the-less.

Maybe an addition to the 'option' declaration in the dialog code could be used to determine mircs behavior with the alt keys. (nokeys,dialogkeys,mirckeys,fallbackkeys,whatever)


"Allen is having a small problem and needs help adjusting his attitude" - Flutterby