Announcement

Collapse
No announcement yet.

Official release of my First commercial DDT Designer (only $29)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Official release of my First commercial DDT Designer (only $29)

    Its finally here!

    The official release of the EZGUI Utility Dialog Designer 4.01 !

    For some screenshots read this post:

    User to user discussions of third-party addons and user-recommended links to related web sites. Advertisements are permitted only in this forum, for products designed to work with and enhance PowerBASIC compilers.


    This Designer generates 100% Source Code !

    No runtimes! No DLL's ! :applaus:

    The Designer also produces very small EXE's. :racer:

    Now for some details:

    The Designer is based on the EZGUI 4.0 Pro Visual Designer and it supports the same file format.

    It can also read the form files (FMZ) created using any of my Freeware DDT Designers (they though can't read its files).

    The Library code is in an include file and at its minimum it adds only 12 KB to the EXE size and at its maximum it only adds 29 KB to the size of the EXE.

    It supports Fonts, Colors, simple regions, Event engine, scrollbar event engine, loading Bitmaps and Icons.

    The Designer can put Bitmaps and icons into a Resource file and autocompile the resource file before displaying your code editor.

    There is a menu editor.

    The Designer works with projects so you can design your entire project at one time. You can quickly move from form to form in the designer.

    The Designer does not use a builtin code editor. It uses external code editors and you can use your faviorite code editor. Both the PB IDE and JellyFish work well with it. You must though have the PB 8.xx Win compiler (early versions of the compiler are not supported).

    The Designer sports a unique Smart Parser technology that allows the designer to literally rewrite your source code after changes to the project.

    The Designer supports the ability to add an include file where you can add your own Events to the event engine.

    It also sports code plugins, which you can write yourself (details can be requested on my forums). Plugins can be used to modify the source code after it is generated, but before it is passed to your code editor.

    The Designer supports the following controls:

    - Button
    - Picture Button
    - Icon Button
    - CheckBox
    - Radio
    - TextBox
    - ListBox
    - Combobox
    - V ScrollBar and H ScrollBar
    - Frame
    - Label
    - Picture
    - Icon
    - PB Graphic control

    It also supports custom controls. Through the custom control object you can use controls like EGrid and SIGrid. You can even use it to add common controls if you wish (requires a little bit of your own coding).

    This designer is the lite version of a PRO version which is still in development. Don't underestimate it. It is very powerful and you can build very fast and small applications. You can have many dozens of forms in a project and up to 750 controls per form.

    The code style is a sort of hybrid approach. There is an Event engine, so control event routines (callbacks not used) get real events, rather than simply API notification messages. For example, all the controls that can respond to a mouse click get the %EZ_Click event. There is no need to memorize the click notification constant for every single control type.

    The event engine also supports a simple %EZ_Notify event for handling the WM_NOTIFY notification messages.

    Lastly, the PRICE !

    This designer is extremely affordable.

    It is only $29 (US).

    What commercial designer can you buy for $29 ?

    You can order from my web site today if you like!

    I will be adding more info about the product on my web site in the days to come.

    To order visit my web site at: http://cwsof.com
    Last edited by Chris Boss; 18 Feb 2008, 08:59 PM.
    Chris Boss
    Computer Workshop
    Developer of "EZGUI"
    http://cwsof.com
    http://twitter.com/EZGUIProGuy

  • #2
    Some other features:

    The Designer has a snap to grid when laying out controls on a Form. You can set it to multiple grid settings (character size, 1 x 1 pixel, 2 x 2 pixel, etc.).

    You can turn the Grid Display ON and OFF (meaning Visible or not visible).

    You can set the grid to display as lines or dots, solid or XOR'ed.

    You can toggle the drag handles to inside or outside of the controls.

    Invisible backgrounds are supported for labels, checkboxes and radio controls.

    The combobox can have a background color, including the drop down part. The library code has code to make this possible.

    You can save Forms as Templates which will display in the "New Form" dialog. This makes it easier to create new forms exactly the way you like it.

    The project properties can be saved as a new default setting for new projects. Simply click a button and the current settings bcome the default for all new projects.

    You can import Visual basic Forms.

    There is a real test mode! See how your form will really look!

    You can select controls as a group (use CTRL key and select with mouse) and then align the controls in a group. You can even change common properties of controls as a group (ie. click on 10 buttons and display a property dialog which effects all 10 controls, but only common attributes, like font, properties, colors).

    Library code supports Font pooling. You can handle fonts in two ways. Use predefined fonts (10 of them) for all projects (you can select 4 of them yourself) and simply select then via an index (no handles needed). You can also use dynamic fonts (not predefined) and rather than store dozens of font handles, you can access them from a font pool.

    Status Bar coordinates can be toggled between dialog units and pixels.

    Display a background "common screen sizes template" in the designer so you can compare the size of your forms to common screen sizes.

    The Designer supports a form of Bookmarks, rather than the usual undo. You can bookmark a form while editing it multiple times and then back track through the bookmarks to get previous versions.

    There is a full screen mode, where you can hide the Designers captionbar and toolbar, so you have a full screen working area.

    There is a 495 KB HTML help file as well which explains how to use the Designer and gives details on the event engine and the library command set.
    Chris Boss
    Computer Workshop
    Developer of "EZGUI"
    http://cwsof.com
    http://twitter.com/EZGUIProGuy

    Comment


    • #3
      A nice feature of the coding style of the Visual Designer is event consolidation. All the events for the form itself (or a control) being sent to one subroutine. It makes coding a lot easier and more readable.

      ie.

      Code:
      SUB FORM1_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
           SELECT CASE CID&
                ' Form has ID of zero or %EZ_Window
                CASE %EZ_Window
                     SELECT CASE CMsg&
                          CASE %EZ_Loading
                          CASE %EZ_Loaded
                          CASE %EZ_Started
                          CASE %EZ_Close
                          CASE %EZ_FreeNow
                          CASE %EZ_Maximize
                          CASE %EZ_Minimize
                          CASE %EZ_Restore
                          CASE ELSE
                     END SELECT
                CASE %EZ_VSCROLL
                     ' forms vertical scrollbar
                     IF CMsg&=%EZ_Change THEN
                          ' CVal& contains new position
                     END IF
                CASE %EZ_HSCROLL
                     ' forms horizontal scrollbar
                     IF CMsg&=%EZ_Change THEN
                          ' CVal& contains new position
                     END IF
                CASE ELSE
           END SELECT
      END SUB
      Chris Boss
      Computer Workshop
      Developer of "EZGUI"
      http://cwsof.com
      http://twitter.com/EZGUIProGuy

      Comment


      • #4
        Post From the Past

        Chris, not sure how this post became visible without a current reply aside from my own, but I'm sure I speak for many when I say that I really appreciate your work with visual designers. I've used some flavor of your designers in the vast majority of the programming projects I've done since switching from VB6 to PowerBASIC around 2000.
        sigpicMark Pruitt
        [email protected]

        http://ezreregister.com
        Manage 3rd party BlackBerry software registration codes.

        It's not the only way to do it...just the EZ way!

        Comment


        • #5
          Thank you Mark,

          There have been thousands of downloads of my Freeware DDT Designers over the years and even today there is usually a dozen (or two) downloads every month.

          This new generation of DDT Designer is a big step forward and many will benefit from them. These are real tools for real programmers.

          I am working on the PRO version now (called EZGUI Dialog Studio) which will have a lot of bells and whistles. The feedback I get from users of the Utility version will be very helpful in making the PRO version even better.

          The Utility version is not just a lite version of the designer. Its purpose is for building utility type apps with little overhead and a small size. It does not depend upon the common controls and the library code adds very little overhead (as little as 12 KB) to the compiled app. It is no toy, though and can be extended by experienced users since it supports a custom control object which allows you to go beyond its features. It also supports the ability to add your own event code to expand the event engine. You can write your own user event function and simply include it in the project. Then any new events that you create can be used by the app.

          By the use of conditional compiling (using compiler directives) the library code is broken up into sections so only the bare minimum you need will be added to the application. For example, lets say you don't need any fonts or colors, both engines can be turned off so they don't compile into the app.

          Even if you use the entire library code, the added size is only about 29 KB.

          I envision that users will want both versions of the Designer. The Utility version and the Pro version. The utility version is fine tuned for building very small utility type apps (with multiple dialogs) while the pro version will be for high end development with more advanced support and high end features.

          Thats why I don't call it a Lite version. Its purpose is different!

          There will be those who don't want to go beyond this version since it is low cost and they will still be able to push the designer far beyond its original intent. There are a number of programmers who don't use many fancy controls in their apps, but do a lot with the PB Graphic control. This designer will be all they need, since it supports the PB graphic control and all the standard controls.

          Some PB'ers don't use the common controls, but do need support for third party controls like EGrid. This designer again will be all they need, since it supports custom controls and supports the %EZ_Notify event (my EZ version of the WM_NOTIFY message, but an event).

          At the price I am selling it for, everybody can afford it!
          Last edited by Chris Boss; 19 Feb 2008, 12:07 PM.
          Chris Boss
          Computer Workshop
          Developer of "EZGUI"
          http://cwsof.com
          http://twitter.com/EZGUIProGuy

          Comment


          • #6
            I should also note that the designer supports code templates.

            All the code currently is generated by the designer and does not need the code templates. The designer does support though code templates, where you can have code added to key sections of the generated code.

            By writing your own templates you can add your own library code to projects using a template. This will automate the use of user defined library code.

            Here is a blank code template:

            Code:
            Text not within Template Blocks is ignored !
            Internal Macros that can be used within a Template Block are:
            <<O>>   -   Add Spaces to offset text
            <<T>>   -   Expand to Spaces based on Tab setting
              ------------------------------------------------
            <<FIRSTLINES>>
            <<END>>
              ------------------------------------------------
            <<INCLUDES>>
            <<END>>
              ------------------------------------------------
            <<EZINCLUDES>>
            <<END>>
              ------------------------------------------------
            <<CONSTANTS>>
            <<END>>
              ------------------------------------------------
            <<DECLARES>>
            <<END>>
              ------------------------------------------------
            <<GLOBALS>>
            <<END>>
              ------------------------------------------------
            <<EZ_MAIN>>
            <<END>>
              ------------------------------------------------
            <<LIBRARY>>
            <<END>>
              ------------------------------------------------
            **************************************************
            The following sections are embedded in a Forms Dialog
            Procedure the first time it is created. The code will
            not be added to existing Dialog procedures.
            DLGPROCV section is for variables and comes first.
            DLGPROCWM section is for adding window message 
            processing code to the Select Case structure.
            **************************************************
            <<DLGPROCV>>
            <<END>>
              ------------------------------------------------
            <<DLGPROCWM>>
            <<END>>
              ------------------------------------------------
            ****************************************************************
            The following sections embed code in the controls Event routine!
            They are only generated the first time the event routine is
            created. Template code will not be added to existing event
            routines.
            ****************************************************************
            <<BUTTON>>
            <<END>>
              ------------------------------------------------
            <<PBUTTON>>
            <<END>>
              ------------------------------------------------
            <<IBUTTON>>
            <<END>>
              ------------------------------------------------
            <<CHECK>>
            <<END>>
              ------------------------------------------------
            <<RADIO>>
            <<END>>
              ------------------------------------------------
            <<TEXT>>
            <<END>>
              ------------------------------------------------
            <<LISTBOX>>
            <<END>>
              ------------------------------------------------
            <<COMBOBOX>>
            <<END>>
              ------------------------------------------------
            <<SCROLL>>
            <<END>>
              ------------------------------------------------
            <<FRAME>>
            <<END>>
              ------------------------------------------------
            <<LABEL>>
            <<END>>
              ------------------------------------------------
            <<PICTURE>>
            <<END>>
              ------------------------------------------------
            <<ICON>>
            <<END>>
              ------------------------------------------------
            *******************************************
            Canvas is same thing as PB Graphic control!
            *******************************************
            <<CANVAS>>
            <<END>>
              ------------------------------------------------
            <<CUSTOM>>
            <<END>>
              ------------------------------------------------
            The code template supports a macro (<<T>>) for tab spacing so your code will be able to use the current tab spacing setting.

            If you wanted to add say common control support you could put library code of your own in the EZ_MAIN section of the template which initializes the common controls and it will automatically be aded to your programs EZ_Main routine.

            Also the Utility Designer supports custom controls and you can add controls to the designer, even the common controls simply by creating an EZC file (custom control definition file) for the control class.

            The utility designer is fully extendable.
            Chris Boss
            Computer Workshop
            Developer of "EZGUI"
            http://cwsof.com
            http://twitter.com/EZGUIProGuy

            Comment


            • #7
              Orders coming in !!!

              Thank you to all those who have ordered the EZGUI Utility Dialog Designer!

              There have been a good number of orders in just less than 48 hours.

              For this price everyone can afford this designer!



              Now for some interesting info:

              You may find it interesting to know that this Designer is itself an EZGUI 4.0 Pro application. It is a 100% EZGUI 4.0 app with absolutely no calls to the API directly in it. It is a good demonstration of what can be done with my high end product EZGUI 4.0 Pro. All the drag and drop stuff, drag handles, 3D buttons , toolbar and tab control are all easy to do with EZGUI 4.0 Pro.

              Now back to my DDT Designers.

              I have decided that when I release the Studio version of my DDT Designer it will have both designers in it, the Utility Dialog Designer and the Studio version. Two designers in one package. They will serve different purposes. The utility designer will be for writing applications which have minimal GUI needs, but need to be as small as possible. The Studio designer will be for writing much more complex applications with more advanced GUI's.

              It may be awhile before the Studio version is ready though, but for those who buy the Utility version there will be an upgrade path available to the Studio version.

              The Utility Dialog Designer is a great place to start though, since it can do a great deal already.
              Chris Boss
              Computer Workshop
              Developer of "EZGUI"
              http://cwsof.com
              http://twitter.com/EZGUIProGuy

              Comment


              • #8
                Chris,

                Can you clarify what the advantage of having both designers in one package would accomplish? If one had the studio version, they would have everything that the utility version has plus a whole lot more. Would the advantage be in the size of the library code used? Depending on the the designer selected either the smaller or larger library code file would be used?

                Just curious???

                Gary
                Thanks,
                Gary Stout
                gary at sce4u dot com

                Comment


                • #9
                  The Studio version will likely generate a larger amount of code so the EXE's will likely be larger. As I add more code to the library, it may not be possible to control all of it with conditional compiling, so out of necessaity the Studio designer may produce larger EXE's. The Utility Designer will allow you to build those really tiny apps, yet still have the power of a full fledged designer.

                  By putting both designers in one package, then you can choose which one fits your projects needs.

                  Also I actually want the Studio users to use the Utility version to encourage development of templates, plugins and user events functions which can be used by all. This way they can test there addons to make sure they work with both designers.
                  Chris Boss
                  Computer Workshop
                  Developer of "EZGUI"
                  http://cwsof.com
                  http://twitter.com/EZGUIProGuy

                  Comment


                  • #10
                    I just purchased this DDT designer and have been playing with it. For $29 I figured I couldn't go wrong and I have to say that I'm impressed. You do nice work Chris. I am still learning the logic of the generated code but it is coming together quickly for me. I would recommend this purchase for anyone in the market for a designer. Even if you own other designers (like most of us do), it may be worth $29 to see if how Chris has things laid out and if it will work for you. This designer looks fairly complete for general program generation except for tabs, toolbars and a few other controls which apparently Chris will add to a more expensive version. I would think you can add these controls as custom controls but I will have to play with this tool some more. Keep up the good work Chris.

                    Jim

                    Comment


                    • #11
                      James,

                      Thank you for the comments.

                      You might want to read this tutorial on my forums about creating EZC files for defining custom controls (including common controls):



                      It can be done in any text editor, like notepad.
                      Chris Boss
                      Computer Workshop
                      Developer of "EZGUI"
                      http://cwsof.com
                      http://twitter.com/EZGUIProGuy

                      Comment


                      • #12
                        It may be beneficial to see some actual source code for a generated project. I created a simple one Form project and turned off all unnecessary code generation. I wanted to see how small an app I could create. Remember that the library code still has its event engine used, but all other library engines have been turned off.

                        I will remove most of the Comments from the code so you can only the actual compilable code.
                        (I will also add some spacing so you can see code blocks more clearly)

                        Here is the projects one Form:



                        Here is the generated source code:

                        Code:
                        #COMPILE EXE
                        #DIM ALL        
                        '
                        %EZLIB_UseFonts    = 0
                        %EZLIB_UseColors   = 0
                        %EZLIB_UseRegions  = 0
                        %EZLIB_UseNotify   = 0
                        %EZLIB_UseScroll   = 0
                        %EZLIB_UseLoading  = 0
                        %EZLIB_UseAdjust   = 0
                        %EZLIB_UserEvents  = 0
                        '
                        DECLARE SUB EZ_AppCleanUp()
                        '
                        #INCLUDE "C:\ezgui40dlg\includes\ezlib4ut.inc"
                        '
                        DECLARE FUNCTION Main_Initialize(BYVAL VerNum&) AS LONG
                        DECLARE SUB EZ_FORM1_Display(BYVAL hParent&)
                        DECLARE SUB EZ_FORM1_Design(BYVAL hDlg&)
                        DECLARE SUB EZ_FORM1_ParseEvents(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                        '
                        %FORM1_LASTNAME           = 100
                        %FORM1_FIRSTNAME          = 105
                        %FORM1_ADDRESS            = 110
                        %FORM1_CITY               = 115
                        %FORM1_ZIPCODE            = 120
                        %FORM1_STATE              = 125
                        %FORM1_LABEL1             = 130
                        %FORM1_LABEL2             = 135
                        %FORM1_LABEL3             = 140
                        %FORM1_LABEL4             = 145
                        %FORM1_LABEL5             = 150
                        %FORM1_LABEL6             = 155
                        %FORM1_ADDBUTTON          = 160
                        %FORM1_FINDBUTTON         = 165
                        %FORM1_SAVEBUTTON         = 170
                        '
                        DECLARE CALLBACK FUNCTION FORM1_DlgProc
                        DECLARE SUB FORM1_ADDBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_FINDBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_SAVEBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                        '
                        GLOBAL hFORM1 AS LONG     ' Dialog Handle
                        '
                        %EZDlgStdVersion   =  4010
                        '
                        DECLARE SUB EZ_Main(BYVAL VerNum&)
                        '
                        #INCLUDE "C:\ezgui40dlg\includes\dlgmain.inc"                          ' Include file for PBMain code
                        '
                        SUB EZ_Main(BYVAL VerNum&)     ' (PROTECTED)
                             DIALOG FONT "SYSTEM", 10
                             EZ_DefImageFolder "Graphics"
                             IF Main_Initialize(VerNum&) THEN
                                  EZ_FORM1_Display 0
                             END IF
                        END SUB
                        '
                        FUNCTION Main_Initialize(BYVAL VerNum&) AS LONG
                             LOCAL RV&
                             RV&=1
                             FUNCTION=RV&
                        END FUNCTION
                        '
                        SUB EZ_AppCleanUp() ' Last Sub called when app terminates
                        END SUB
                        '
                        SUB EZ_FORM1_Display(BYVAL hParent&)     ' (PROTECTED)
                             LOCAL T$, X&, Y&, W&, H&, WS&, EWS&, hDlg&, EVAdd AS DWORD
                             T$ = "Address Book example"
                             X& = EZLIB_GetNextDlgX
                             Y& = EZLIB_GetNextDlgY
                             W& =  264
                             H& =  184
                             WS& =%WS_POPUP OR %WS_CAPTION OR %WS_SYSMENU OR %WS_DLGFRAME OR %DS_CENTER
                             EWS& =0
                             EVAdd = CODEPTR(EZ_FORM1_ParseEvents)
                             IF EZLIB_LoadingEvent(0, T$, X&, Y&, W&, H&, WS&, EWS&, EVAdd) THEN EXIT SUB
                             DIALOG NEW UNITS,  hParent&, T$, X&, Y&, W&, H&, WS&, EWS&, TO hDlg&
                             hFORM1 = hDlg&
                             EZ_FORM1_Design hDlg&
                             DIALOG SHOW MODELESS hDlg&, CALL FORM1_DlgProc
                        END SUB
                        '
                        SUB EZ_FORM1_Design(BYVAL hDlg&)     ' (PROTECTED)
                             LOCAL WS&, EWS&, hCtrl&, hTemp&, EVAdd AS DWORD, AW&, AH&
                             EVAdd = CODEPTR(EZ_FORM1_ParseEvents)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_LASTNAME,  "", 52, 16, 160, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_FIRSTNAME,  "", 52, 36, 120, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_ADDRESS,  "", 52, 56, 204, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_CITY,  "", 52, 76, 204, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_ZIPCODE,  "", 52, 116, 68, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_STATE,  "", 52, 96, 152, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL1,  "Last Name:", 8, 18, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL2,  "First Name", 8, 38, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL3,  "Address", 8, 58, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL4,  "City", 8, 78, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL5,  "State", 8, 98, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL6,  "Zip Code:", 8, 118, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_ADDBUTTON,  "Add New Address", 8, 152, 60, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_FINDBUTTON,  "Find Address", 80, 152, 60, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_SAVEBUTTON,  "Save Address", 152, 152, 96, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                        END SUB
                        '
                        SUB EZ_FORM1_ParseEvents(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)     ' (PROTECTED)
                             SELECT CASE CID&
                                  CASE %EZ_Window
                                       FORM1_Events hDlg&, CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_ADDBUTTON
                                       FORM1_ADDBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_FINDBUTTON
                                       FORM1_FINDBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_SAVEBUTTON
                                       FORM1_SAVEBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE ELSE
                                       FORM1_Events hDlg&, CID&, CMsg&, CVal&, Cancel&
                             END SELECT
                        END SUB
                        '
                        SUB FORM1_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CID&
                                  CASE %EZ_Window
                                       SELECT CASE CMsg&
                                            CASE %EZ_Loaded
                                            CASE %EZ_Started
                                            CASE ELSE
                                       END SELECT
                                  CASE ELSE
                             END SELECT
                        END SUB
                        '
                        CALLBACK FUNCTION FORM1_DlgProc
                             SELECT CASE CBMSG
                                  CASE %WM_DESTROY
                                  CASE ELSE
                             END SELECT
                             FUNCTION=EZLIB_DLGEvents(CBHNDL, CBMSG, CBWPARAM, CBLPARAM, CODEPTR(EZ_FORM1_ParseEvents))
                        END FUNCTION
                        '
                        SUB FORM1_ADDBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                        '
                        SUB FORM1_FINDBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                        '
                        SUB FORM1_SAVEBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                        I compiled the program (of course no event code guts have been added) and it compiled to just 35 KB.

                        I used one of my freeware designers, which produces the smallest possible EXE and I created a similiar form with the same number of controls and it compiled to 25 KB.

                        I think, even despite the library code and event engine, the new Visual Designers code generation is quite efficient to producing small apps.

                        Here is the actual code, unedited (all comments and original spacing)

                        Code:
                        ' *************************************************************************************
                        '             Code Generated by EZGUI Utility Dialog Designer 4.010
                        '             Portions: Copyright Christopher R. Boss, 2003 to 2008
                        '                              All Rights Reserved !
                        ' Registered EZGUI Utility Dialog Designer 4.010 users may use this code Royalty Free !
                        ' *************************************************************************************
                        '
                        ' --------------------------------------------------------
                        ' WARNING ! Do Not Modify any code WITHIN Protected Sections !
                        ' You can add code (Sub,Function,etc.) BEFORE any Protected Routine
                        ' by using the following CODE TAGS:        '<<SAVE>>      '<<END>>
                        ' and the Designer will not remove it.
                        ' --------------------------------------------------------
                        '
                        ' ======================================
                        ' [PROTECTED CODE]         Do NOT Edit !
                        ' ======================================
                        
                        '
                        #COMPILE EXE
                        #DIM ALL        '   This is helpful to prevent errors in coding
                        ' ---------------------
                        %EZLIB_UseFonts    = 0
                        %EZLIB_UseColors   = 0
                        %EZLIB_UseRegions  = 0
                        %EZLIB_UseNotify   = 0
                        %EZLIB_UseScroll   = 0
                        %EZLIB_UseLoading  = 0
                        %EZLIB_UseAdjust   = 0
                        %EZLIB_UserEvents  = 0
                        ' ---------------------
                        ' --------------------
                        DECLARE SUB EZ_AppCleanUp()
                        #INCLUDE "C:\ezgui40dlg\includes\ezlib4ut.inc"
                        ' --------------------
                        ' *************************************************************************************
                         
                        ' *************************************************************************************
                        '                   Code Generator Defined Constants and Declares
                        ' *************************************************************************************
                        DECLARE FUNCTION Main_Initialize(BYVAL VerNum&) AS LONG
                        DECLARE SUB EZ_FORM1_Display(BYVAL hParent&)
                        DECLARE SUB EZ_FORM1_Design(BYVAL hDlg&)
                        DECLARE SUB EZ_FORM1_ParseEvents(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                        ' ------------------------------------------------
                        %FORM1_LASTNAME           = 100
                        %FORM1_FIRSTNAME          = 105
                        %FORM1_ADDRESS            = 110
                        %FORM1_CITY               = 115
                        %FORM1_ZIPCODE            = 120
                        %FORM1_STATE              = 125
                        %FORM1_LABEL1             = 130
                        %FORM1_LABEL2             = 135
                        %FORM1_LABEL3             = 140
                        %FORM1_LABEL4             = 145
                        %FORM1_LABEL5             = 150
                        %FORM1_LABEL6             = 155
                        %FORM1_ADDBUTTON          = 160
                        %FORM1_FINDBUTTON         = 165
                        %FORM1_SAVEBUTTON         = 170
                        DECLARE CALLBACK FUNCTION FORM1_DlgProc
                        DECLARE SUB FORM1_ADDBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_FINDBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                        DECLARE SUB FORM1_SAVEBUTTON_Events(MyID&, CMsg&, CVal&, Cancel&)
                         
                        ' *************************************************************************************
                        '                 Code Generator Defined Global Variables and Types
                        ' *************************************************************************************
                        ' --- Form: FORM1 ---
                        GLOBAL hFORM1 AS LONG     ' Dialog Handle
                         
                        ' --------------------
                        %EZDlgStdVersion   =  4010
                        DECLARE SUB EZ_Main(BYVAL VerNum&)
                        #INCLUDE "C:\ezgui40dlg\includes\dlgmain.inc"                          ' Include file for PBMain code
                        ' --------------------
                         
                        ' *************************************************************************************
                        '                       User Defined Global Variables and Types
                        '         (Put code in CODE TAGS! to protect from deletion by Code Generator !)
                        ' *************************************************************************************
                        SUB EZ_Main(BYVAL VerNum&)     ' (PROTECTED)
                             DIALOG FONT "SYSTEM", 10
                             EZ_DefImageFolder "Graphics"
                             IF Main_Initialize(VerNum&) THEN
                                  EZ_FORM1_Display 0
                             END IF
                        END SUB
                        
                        ' ======================================
                        ' [USER ACCESSABLE CODE]  You may Edit !
                        ' ======================================
                        
                        FUNCTION Main_Initialize(BYVAL VerNum&) AS LONG
                             LOCAL RV&
                             RV&=1
                             FUNCTION=RV&
                        END FUNCTION
                        SUB EZ_AppCleanUp() ' Last Sub called when app terminates
                             ' Call Form _FreeRes routines here if not called in Forms WM_DESTROY message
                        END SUB
                         
                        
                        ' *************************************************************************************
                        '                                Applications FORM Code
                        ' *************************************************************************************
                        
                        '<<BEGINFORM>> "FORM1"
                        
                        ' ======================================
                        ' [PROTECTED CODE]         Do NOT Edit !
                        ' ======================================
                        SUB EZ_FORM1_Display(BYVAL hParent&)     ' (PROTECTED)
                             LOCAL T$, X&, Y&, W&, H&, WS&, EWS&, hDlg&, EVAdd AS DWORD
                             T$ = "Address Book example"
                             X& = EZLIB_GetNextDlgX
                             Y& = EZLIB_GetNextDlgY
                             W& =  264
                             H& =  184
                             WS& =%WS_POPUP OR %WS_CAPTION OR %WS_SYSMENU OR %WS_DLGFRAME OR %DS_CENTER
                             EWS& =0
                             EVAdd = CODEPTR(EZ_FORM1_ParseEvents)
                             IF EZLIB_LoadingEvent(0, T$, X&, Y&, W&, H&, WS&, EWS&, EVAdd) THEN EXIT SUB
                             DIALOG NEW UNITS,  hParent&, T$, X&, Y&, W&, H&, WS&, EWS&, TO hDlg&
                             hFORM1 = hDlg&
                             EZ_FORM1_Design hDlg&
                             DIALOG SHOW MODELESS hDlg&, CALL FORM1_DlgProc
                        END SUB
                        SUB EZ_FORM1_Design(BYVAL hDlg&)     ' (PROTECTED)
                             LOCAL WS&, EWS&, hCtrl&, hTemp&, EVAdd AS DWORD, AW&, AH&
                             EVAdd = CODEPTR(EZ_FORM1_ParseEvents)
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_LASTNAME,  "", 52, 16, 160, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_FIRSTNAME,  "", 52, 36, 120, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_ADDRESS,  "", 52, 56, 204, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_CITY,  "", 52, 76, 204, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_ZIPCODE,  "", 52, 116, 68, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Text]
                             WS& =  %ES_AUTOHSCROLL OR %ES_LEFT OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = %WS_EX_CLIENTEDGE
                             hCtrl&=EZLIB_AddControl("EDIT", hDlg&,  %FORM1_STATE,  "", 52, 96, 152, 12, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL1,  "Last Name:", 8, 18, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL2,  "First Name", 8, 38, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL3,  "Address", 8, 58, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL4,  "City", 8, 78, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL5,  "State", 8, 98, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Label]
                             WS& =  %SS_CENTER OR %SS_NOPREFIX OR %WS_VISIBLE OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("STATIC", hDlg&,  %FORM1_LABEL6,  "Zip Code:", 8, 118, 36, 8, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Button]
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_ADDBUTTON,  "Add New Address", 8, 152, 60, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Button]
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_FINDBUTTON,  "Find Address", 80, 152, 60, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                             ' [Button]
                             WS& =  %BS_PUSHBUTTON OR %WS_VISIBLE OR %WS_TABSTOP OR %WS_CHILD OR %WS_CLIPSIBLINGS OR %WS_CLIPCHILDREN
                             EWS& = 0
                             hCtrl&=EZLIB_AddControl("BUTTON", hDlg&,  %FORM1_SAVEBUTTON,  "Save Address", 152, 152, 96, 20, WS&, EWS&, 0, EVAdd, 1, 0)
                             ' -----------------------------------------------
                        END SUB
                        
                        SUB EZ_FORM1_ParseEvents(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)     ' (PROTECTED)
                             SELECT CASE CID&
                                  CASE %EZ_Window
                                       FORM1_Events hDlg&, CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_ADDBUTTON
                                       FORM1_ADDBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_FINDBUTTON
                                       FORM1_FINDBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE  %FORM1_SAVEBUTTON
                                       FORM1_SAVEBUTTON_Events CID&, CMsg&, CVal&, Cancel&
                                  CASE ELSE
                                       FORM1_Events hDlg&, CID&, CMsg&, CVal&, Cancel&
                             END SELECT
                        END SUB
                        ' ======================================
                        ' [USER ACCESSABLE CODE]  You may Edit !
                        ' ======================================
                        SUB FORM1_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CID&
                                  CASE %EZ_Window
                                       SELECT CASE CMsg&
                                            CASE %EZ_Loaded
                                            CASE %EZ_Started
                                            CASE ELSE
                                       END SELECT
                                  CASE ELSE
                             END SELECT
                        END SUB
                        ' #################################################################
                        '              Dialog Procedure for FORM1
                        ' #################################################################
                        CALLBACK FUNCTION FORM1_DlgProc
                             SELECT CASE CBMSG
                                  CASE %WM_DESTROY
                                  CASE ELSE
                             END SELECT
                             ' Pass Messages to EZGUI Default Event Generator
                             ' make sure CODEPTR parameter points to _ParseEvents routine for this form
                             FUNCTION=EZLIB_DLGEvents(CBHNDL, CBMSG, CBWPARAM, CBLPARAM, CODEPTR(EZ_FORM1_ParseEvents))
                        END FUNCTION
                        SUB FORM1_ADDBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                        SUB FORM1_FINDBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                        SUB FORM1_SAVEBUTTON_Events( MyID&, CMsg&, CVal&, Cancel&)
                             SELECT CASE CMsg&
                                  CASE %EZ_Click
                                  CASE ELSE
                             END SELECT
                        END SUB
                         
                        '<<END ALL FORMS>>    UnKnown Routines follow:
                        #IF %EZ_NOSKIPCODE
                        #ENDIF 'PARSE END
                        Last edited by Chris Boss; 22 Feb 2008, 11:48 AM.
                        Chris Boss
                        Computer Workshop
                        Developer of "EZGUI"
                        http://cwsof.com
                        http://twitter.com/EZGUIProGuy

                        Comment


                        • #13
                          Some nice features of the Designer which make development quicker and easier:

                          (1) Listbox and ComboBox property dialogs allow you to fill the controls list at design time. Its as easy as this:

                          Apples|Oranges|Pears|Grapes|Watermellons

                          Just add your list in the property dialog and the code is automatcally generated.

                          (2) No API knowledge required for selecting styles (called properties in the designer). The styles are listed as easy to understand properties, rather than window style constants. This makes it easy for beginners to select the correct styles/properties. No need to read the API docs to learn what a specific window style does.

                          (3) No need to display the Color Common Dialog every time to select a color. Color options are displayed in a project pallete. Colors are broken up into 5 groups.

                          16 colors are same as DOS Basic colors (colors 0 to 15)
                          16 colors are pastel versions of the DOS Basic colors (colors 16 to 31)
                          4 System colors can be defined in the project properties dialog
                          8 user defined colors cab be defined in the project properties dialog
                          56 colors are in the current user shaded palette (thousands of palettes available)

                          This gives you 100 colors in the project palette. Once you select the colors in the project properties dialog, when you display a controls/forms property dialog the color dialog displayed (when you click the FG or BG color button) is always the project palette. Just select a color from the palette.

                          The beauty of this method is that colors are indexed in the project color palette. This means that if you use a specific color in the palette for say dozens of controls and then you later change the palette all the controls automatically use the new colors. The controls are not stuck with a specific RGB color. They are associated with a color index to the project palette.

                          This means you could have a large project with dozens of forms and hundreds of controls and you can change all them by simply changing the project color palette.

                          (4) Font Selection is easier, because there are 10 predefined fonts. Of course, you can still display the font common dialog and select any font you want, but most apps won't need more than the 10 predefined fonts so it is easy to just click on of the font buttons to select the font you want.

                          6 of the fonts are the system stock object fonts
                          4 of the fonts are defined in the Designers configuration dialog (not defined at the project level). These four user defined fonts are assigned to the other 4 font buttons in the control properties dialog. Most applications don't need more than 4 custom fonts, so this allows you to quickly select the fonts from a predefined group of fonts.

                          If you do need a unique font, you can still display the font common dialog and select one.

                          The generated code handles fonts in one of two ways. You can select a font form the 10 predefined fonts (you can add more indexed fonts via code). When the designer must generate references to unique fonts, not part of the predefined list, it generates code which uses Font Pooling. Font Pooling, is where a request is made for s specific font and if the font does not exist, it is created and stored in a pool. If the font is already found in the font pool, that font is used and no new font handle is needed.

                          Font Pooling allows a program to create a lot of fonts, while not adding extra overhead of multiple font handles for the exact same font.

                          (5) Simple Region selection.
                          A number of controls (ie. Label, Picture, Graphic) allow you to select a simple Region, either rounded rectangle or elliptical region. What this means is that you can make a PB Graphic control (or Label) truly round. It is as simple as selecting an option on the control properties dialog.

                          (6) Multi-Lines on Buttons, Radios, Checkboxes and Labels. The Designer uses the | character as an end of line character to separate lines. It is as easy as this:

                          Line 1|Line 2|Line 3|Line 4

                          The library code handles converting the | character to CRLF's.

                          (7) Transparent Background controls.
                          The Radio, Checkbox and Label controls allow you to select the I (Invisible background) property. The generate code handles all that is necessary to display this.

                          (8) Automatic ScrollBar processing.
                          The scrollbars requiring the processing the WM_VSCROLL or WM_HSCROLL messages for them to be active. The library code handles all of this for you and the scrollbars event routine will get an event (%EZ_Change) and the current position is passed to the event. Using scrollbars are now easy to use. Even the forms scrollbars get this event. The forms scrollbars have ID's just like controls, so you can know which one sent the event.
                          Chris Boss
                          Computer Workshop
                          Developer of "EZGUI"
                          http://cwsof.com
                          http://twitter.com/EZGUIProGuy

                          Comment


                          • #14
                            Some more benefits of the EZGUI Utility Dialog Designer:

                            (1) Code Readability!

                            The Designer generates code which is easy to read and is as modular as possible. For example here is the Event routine for a Form (dialog):

                            Code:
                            SUB FORM4_Events(BYVAL hDlg&, BYVAL CID&, CMsg&, CVal&, Cancel&)
                                 SELECT CASE CID&
                                      CASE %EZ_Window
                                           SELECT CASE CMsg&
                                                CASE %EZ_Loading
                                                CASE %EZ_Loaded
                                                CASE %EZ_Started
                                                     SLEEP 3000
                                                     EZ_SetNextDlgPos 10,10
                                                     EZ_FORM1_Display 0
                                                     DIALOG END hDlg&
                                                CASE %EZ_Close
                                                CASE %EZ_FreeNow
                                                     ' Form FreeRes routine can be called here!
                                                CASE %EZ_Maximize
                                                CASE %EZ_Minimize
                                                CASE %EZ_Restore
                                                CASE ELSE
                                           END SELECT
                                      CASE ELSE
                                 END SELECT
                            END SUB
                            Notice there are not a lot of parameters passed to the event routine. The events are easy to understand and to work with. You are shielded from the API as much as is practical.

                            Also notice the Forms Event routine passes the CID& parameter, which is a controls ID. The purpose of this, is that if a control is created outside of the Designer generated code (ie. you create controls yourself via code in some event), it won't have a generated event routine to match it. The parsing routines which parses out events, will send all unknown control events (no event routine found in app) to the forms event routine, including its ID. This allows you to write event code, even for controls created dynamically via code from events.

                            Also notice the 3 events, for the form, %EZ_Loading, %EZ_Loaded, %EZ_Started. What are they ?

                            %EZ_Loading occurs before the Form is created. The library code provides commands to read the current form parameters and commands to change them. This allows you to dynamically modify the forms creation parameters, before it is created, yet not have to modify the actual form creation code generated by the designer.

                            %EZ_Loaded occurs after the form is created and the controls are created, but before the form is displayed (same as WM_INITDIALOG).

                            %EZ_Started is a posted event, so it occurs after %EZ_Loaded, but also after all pending events in the message que are process, so it should occur when the form is actually displayed.

                            (2)Hybrid Event code
                            The Hybrid event code method of coding is quite simple. The Designer does generate an actual Dialog Procedure for each Form. If you prefer to handle some window messages like you normally do by writing code in the dialog procedure, you can do so. The Designer though generates the following default code in the Dialog procedure:

                            Code:
                            CALLBACK FUNCTION FORM4_DlgProc
                                 SELECT CASE CBMSG
                                      CASE ELSE
                                 END SELECT
                                 FUNCTION=EZLIB_DLGEvents(CBHNDL, CBMSG, CBWPARAM, CBLPARAM, CODEPTR(EZ_FORM4_ParseEvents))
                            END FUNCTION
                            I removed some unnessary code (and comments), but left the core event code in the dialog procedure. Notice after the Select Case structure a call is made to a function called EZLIB_DLGEvents. This function is in the library code (in an include file). This function processes all window messages through the library codes Event engine. If the event engine recognizes a message, it will convert it into a simple Event and send that event to the appropiate event routine.

                            This gives you the best of both worlds.

                            You can use the generated events and write simple event code.

                            or

                            You can write standard Dialog procedure style code in the dialog procedure, when you need it (ie. event engine doesn't process the message).

                            (3)Expandable Event engine
                            The event engine in the library code is expandable. You don't have to attempt to modify the library code (I also would not recommend it). The Designer lets you set a project property, where you can define an include file with a User Define Event engine. A template for this code is provided, which is:

                            Code:
                            ' ---------------------
                            ' User events template
                            ' ---------------------
                            '
                            ' This code is public domain and can be modified any way you choose and distributed to third parties.
                            ' The Functions name and parameters though must not be changed!
                            ' Define your own Events here!
                            ' User defined Events should start with the value of %EZ_User so they don't conflict with existing events.
                            %MY_LButtonDown     =    %EZ_USER + 1
                            FUNCTION EZLIB_UserEvents(BYVAL hDlg AS LONG, BYVAL Msg AS LONG, BYVAL wParam AS LONG, BYVAL lParam AS LONG, BYVAL EventAddress AS DWORD, RV AS LONG) AS LONG
                                 LOCAL CVal&, Cancel&
                                 ' if function returns non-zero then no more event processing is done by EZ Library code for this message
                                 ' RV is the return value for to the Dialog procedure. Set to non-zero to prevent default processing.
                                 SELECT CASE Msg     ' Window messages
                                      CASE %WM_LBUTTONDOWN
                                           CVal&=lParam   ' pass mouse position in CVal&
                                           EZLIB_SendEvent hDlg, %EZ_Window, %MY_LButtonDown, CVal&, Cancel&, EventAddress
                                           RV&=0
                                           FUNCTION=1
                                      CASE ELSE
                                 END SELECT
                            END FUNCTION
                            If your project includes a user Defined event engine, the library code will call it before processing any messages. Your user event function can add new events to the engine. You simply define new event constants and then process the window messages in this routine. Once you have a well designed user event engine, it can be used with all your projects. The library code has a command EZLIB_SendEvent which you can use in your user event engine code to actually generate an event. The library code will handle passing the event to the corrent control/form event routine.

                            This means the event engine is fully expandable!

                            (4)Library code versus Inline code balance
                            One difficult choice to make is whether code should be totally inline for many features or whether it should be library code (easy to call function/sub). The Designer balances this out very well. If the inline code can be generated in just a few lines of code, then the Designer generates inline code when needed. If though the code is a number of lines, the designer generates calls to well written library functions/subs. This allows for cleaner code in the generated app code, while leaving more complex code in the library. Initially, this may add a few extra KB (kilobytes) to the final apps size (compiled exe) because of embeding library code, but as a project gets bigger and bigger, the library code should produce a more efficient application and the size should be smaller than pure inline code.

                            ie.
                            Code:
                            SUB EZ_FORM4_Display(BYVAL hParent&)     ' (PROTECTED)
                                 LOCAL T$, X&, Y&, W&, H&, WS&, EWS&, hDlg&, EVAdd AS DWORD
                                 T$ = "Your Dialog"
                                 X& = EZLIB_GetNextDlgX
                                 Y& = EZLIB_GetNextDlgY
                                 W& =  196
                                 H& =  128
                                 WS& =%WS_POPUP OR %WS_BORDER OR %DS_CENTER
                                 EWS& =0
                                 EZLIB_AddDlgOffsets WS&, EWS&, W&, H&, 0
                                 EVAdd = CODEPTR(EZ_FORM4_ParseEvents)
                                 IF EZLIB_LoadingEvent(0, T$, X&, Y&, W&, H&, WS&, EWS&, EVAdd) THEN EXIT SUB
                                 DIALOG NEW UNITS,  hParent&, T$, X&, Y&, W&, H&, WS&, EWS&, TO hDlg&
                                 hFORM4 = hDlg&
                                 DIALOG SET COLOR hDlg&, -1&, EZ_ColorVal(30)
                                 EZ_FORM4_Design hDlg&
                                 DIALOG SHOW MODELESS hDlg&, CALL FORM4_DlgProc
                            END SUB
                            Notice the code above. Much of it is inline code, while there are a few called functions (ie. EZLIB_AddDlgOffsets, EZLIB_LoadingEvent). The library code is very modular and it allows the overall source code to be more readable and easier to work with.

                            (5) Code Backup protection
                            The Designer uses a Smart Parser which allows you to use any compatible external code editor (ie. PB IDE, JellyFish). The Smart Parser has to make updates of code in your application, every time you regenerate code (when modifying the GUI). It does two things to protect your code to prevent accidently losing important code. The first is when controls or forms are deleted (or names changed) and the Designer needs to remove their code from the app, it doesn't immediately delete it. At the end of the apps main source code file is the followoing compiler directive:

                            Code:
                            #IF %EZ_NOSKIPCODE
                                   '
                            #ENDIF 'PARSE END
                            If the Smart Parser deletes code (ie. a control is deleted from a form), it will move the previous source code for that control/form to the end of the app and place it inside the skip code compiler directive. This allows the code to stay in your source code file, while preventing it from being compiled into your app. The purged code stays in this skip code compiler directive, until you manually delete it.

                            The Designer also backs up the source code file, when ever it regenerates it. After you have regenerated an app a few times, you will notice that the designer will produce multiple copies of the source code, such as:

                            myapp.bas (current source)
                            myapp.bs1 (previous version of source)
                            myapp.bs2 (version prior to one above)

                            When you regenerate code, the designer changes the filenames like this:

                            Myapp.bas becomes myapp.bs1
                            myapp.bs1 becomes myapp.bs2

                            and then it generates a new myapp.bas

                            This means at any one time, you have at least two previous versions of the app from the currently generated one.
                            Chris Boss
                            Computer Workshop
                            Developer of "EZGUI"
                            http://cwsof.com
                            http://twitter.com/EZGUIProGuy

                            Comment


                            • #15
                              You can download a version of the help file which may be useful in learning more about the product here:

                              http://cwsof.com/download/dlghelp.zip
                              Chris Boss
                              Computer Workshop
                              Developer of "EZGUI"
                              http://cwsof.com
                              http://twitter.com/EZGUIProGuy

                              Comment

                              Working...
                              X