From WikiChip
Editing mirc/dialogs
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
This page supports semantic in-text annotations (e.g. "[[Is specified as::World Heritage Site]]") to build structured and queryable content provided by Semantic MediaWiki. For a comprehensive description on how to use annotations or the #ask parser function, please have a look at the getting started, in-text annotation, or inline queries help pages.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | {{ | + | {{mIRC Guide}} |
− | + | [[Category:mIRC]] | |
+ | '''Dialogs''' make it possible to create custom dialog windows inside of mIRC. The [[/dialog command - mIRC|/dialog command]] is the key way to opening new dialogs, and the [[Dialog components - mIRC|Dialog components]] are the objects within the dialog, such as buttons, labels, etc. | ||
+ | |||
+ | == Questions == | ||
=== What dialogs are === | === What dialogs are === | ||
Dialogs are simply [[graphical user interfaces]] that present options to a user's screen in a graphical form. For instance, a web browser is display through its own dialog. Windows users may have used applications such as notepad, or Microsoft Word. All of these applications use dialogs, or forms of [[graphical user interfaces]] to present their applications in an appealing form. | Dialogs are simply [[graphical user interfaces]] that present options to a user's screen in a graphical form. For instance, a web browser is display through its own dialog. Windows users may have used applications such as notepad, or Microsoft Word. All of these applications use dialogs, or forms of [[graphical user interfaces]] to present their applications in an appealing form. | ||
=== mIRC Dialogs === | === mIRC Dialogs === | ||
− | mIRC dialogs are created by users through custom scripts. Through these dialog interactions, the dialogs adhere to an event listener, the | + | mIRC dialogs are created by users through custom scripts. Through these dialog interactions, the dialogs adhere to an event listener, the [[On dialog - mIRC|ON DIALOG]] event. Through this event, all aspects of the custom dialogs, as well as their controls, can be monitored, tracked, and modified. |
− | + | == Scope == | |
− | The scope of this article is to generally familiarize users with the term '''dialogs''', and what exactly it is they are used for within mIRC. Since these components are geared towards more advanced scripters, beginners should make sure they have already gone through the preceding tutorials from the | + | The scope of this article is to generally familiarize users with the term '''dialogs''', and what exactly it is they are used for within mIRC. Since these components are geared towards more advanced scripters, beginners should make sure they have already gone through the preceding tutorials from the [[Introduction - mIRC|mIRC Introduction]] page, all the way leading up to '''Dialogs''' |
− | + | == Two types of dialog == | |
− | They are two type of | + | They are two type of dialog, modeless dialog and modal dialog, modeless dialog. |
Modals dialog are dialog which block the current script execution, you cannot access others windows, usually used to get a quick user input. | Modals dialog are dialog which block the current script execution, you cannot access others windows, usually used to get a quick user input. | ||
− | mIRC has built-in modals dialog, {{mIRC|$?}}'s | + | mIRC has built-in modals dialog, {{mIRC|$?}}'s famillies and {{mIRC|$input}} are modals dialogs. |
Modeless dialog can be opened indefinitely and does not halt the script execution. | Modeless dialog can be opened indefinitely and does not halt the script execution. | ||
+ | mIRC also has modeless dialog, such as the mIRC Options dialog (alt + o). | ||
− | + | You can create both custom modal and modeless dialog. | |
− | |||
− | You can create | ||
− | |||
− | |||
− | |||
− | |||
− | + | == Creating a dialog table == | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
Custom dialogs are created by defining a dialog table, the content of that table represents the look of the dialog, the controls etc, a table is defined by using the <dialog> keyword: | Custom dialogs are created by defining a dialog table, the content of that table represents the look of the dialog, the controls etc, a table is defined by using the <dialog> keyword: | ||
− | + | dialog -l <name> { | |
− | + | title "text" | |
− | + | icon filename, index | |
− | + | size x y w h | |
− | + | option type (dbu, pixels, notheme, disable) | |
− | + | text "text", id, x y w h, style (right, center, nowrap) | |
− | + | edit "text", id, x y w h, style (right, center, multi, pass, read, return, hsbar, vsbar, autohs, autovs, limit N, rich) | |
− | + | button "text", id, x y w h, style (default, ok, cancel, flat, multi) | |
− | + | check "text", id, x y w h, style (left, push, 3state) | |
− | + | radio "text", id, x y w h, style (left, push) | |
− | + | box "text", id, x y w h, style | |
− | + | scroll "text", id, x y w h, style (top left bottom right horizontal range N N) | |
− | + | list id, x y w h, style (sort, extsel, multsel, size, vsbar, hsbar, check, radio) | |
− | + | combo id, x y w h, style (sort, edit, drop, size, vsbar, hsbar) | |
− | + | icon id, x y w h, filename, index, style (noborder top left bottom right small large actual) | |
− | + | link "text", id, x y w h | |
− | + | tab "text", id, x y w h | |
− | + | tab "text", id | |
− | + | menu "text", menuid [, menuid] | |
− | + | item "text", id [, menuid] | |
− | + | item break, id [, menuid] | |
− | } | + | } |
The -l switch makes the table local, only that script file can open it. <name> is the name of table which will be used to create an instance of that dialog | The -l switch makes the table local, only that script file can open it. <name> is the name of table which will be used to create an instance of that dialog | ||
Line 85: | Line 60: | ||
* size - Required, set the size of the dialog, you can use -1 for any of the x, y, w and h parameter to specify a default position, x and y sets as -1 should center the dialog in the window | * size - Required, set the size of the dialog, you can use -1 for any of the x, y, w and h parameter to specify a default position, x and y sets as -1 should center the dialog in the window | ||
* option - Can be used to set different options for the dialog, type is a space seperated list of options: | * option - Can be used to set different options for the dialog, type is a space seperated list of options: | ||
− | + | ** dbu - This option will ensure the dialog looks the same under any size display using dialog base units | |
− | ** dbu - | + | ** pixels - This option is set by default if you don't use the dbu option, it uses simple pixels value to display |
− | ** | + | ** notheme - This option prevents mIRC from applying a your current windows theme to the dialog |
− | ** notheme - This option prevents mIRC from applying your current windows theme to the dialog | ||
** disable - This option can use used to wait a bit before the controls in the dialog can be used, preventing accidents | ** disable - This option can use used to wait a bit before the controls in the dialog can be used, preventing accidents | ||
− | * Others elements are used to create controls, see the | + | * Others elements are used to create controls, see the |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | == Modeless dialog == | |
− | {{mIRC| | + | You can create a modeless dialog using the {{mIRC|/dialog}} command with the -m switch, there are others switch that can be used at creation and after the creation of the dialog to change various states. |
− | |||
− | |||
− | + | If users are comfortable with mIRC already, and are ready to dive into dialogs, the next step would be to check out the [[Dialog Components - mIRC|Dialog Components]] page. | |
== See Also == | == See Also == | ||
− | * | + | * [[Dialog Components - mIRC|Dialog Components]] |
− | * | + | * [[On dialog - mIRC|ON DIALOG Event]] |
− | [[ |