kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #03447
Re: What tools are we using for wxWidgets if any?
-
To:
kicad-devel@xxxxxxxxxxxxxxx
-
From:
jean-pierre charras - INPG <jean-pierre.charras@...>
-
Date:
Mon, 26 Oct 2009 11:12:30 +0100
-
In-reply-to:
<4AE4EEBC.3030203@...>
-
User-agent:
Thunderbird 2.0.0.23 (Windows/20090812)
Dick Hollenbeck a écrit :
Rob Frohne wrote:
> Hi Everyone,
>
> I checked out the source and have been looking at it a little. I'm not
> highly familiar with wxWidgets, but there seem to be a number of GUI
> design tools that developers have to use for more rapid development
with
> wxWidgets. Are any of these being used? Are there any docs on any
> guidelines on patches?
>
> Thanks,
>
> Rob
>
>
wxFormBuilder is being used.
Yes, currently we use wxFormBuilder (a free and GPL tool to create
dialogs for wxWidgets).
Some previous dialogs were created using DialogBlocks, and the oldest
dialogs were write "by hand"
This fact explains some difference between the look of some dialogs.
When an "old" dialog is modified, it is redesigned with wxFormBuilder .
wxFormBuilder creates a "basic" dialog, and automatically creates the
.cpp and .h corresponding files
After changes in the dialog frame, it recreates these files.
Therefore, in order to allow these changes without lost of code you must :
1 - create the basic dialog window, said named MY_DIALOG_BASE, (or
MY_DIALOG_FBP) and create the corresponding files my_dialog_base.*
(.fbp, .cpp and .h files)
and *do not edit these files* by hand.
2 - create a derived class from MY_DIALOG_BASE, said MY_DIALOG and the
corresponding files my_dialog.cpp and .h .
This class includes only the specific methods and members not already
created by wxFormBuilder, i.e. items that are not wxWidgets widgets.
So when modify the dialog, my_dialog_base.cpp and my_dialog_base.h files
are recreated, but the code made by hand is not destroy because it is
only in my_dialog.cpp.
Note also all strings that must be translated (like GUI messages) cannot
*NOT* be static, because static strings are built by their constructor
before the current locale is known.
In cases where strings cannot be static ( cannot be created "on the fly"
at run time) the wxGetTranslation must be called explicitely before
using these string.
--
Jean-Pierre CHARRAS
Maître de conférences
Directeur d'études 2ieme année.
Génie Electrique et Informatique Industrielle 2
Institut Universitaire de Technologie 1 de Grenoble
BP 67, 38402 St Martin d'Heres Cedex
Recherche :
Grenoble Image Parole Signal Automatique (GIPSA - INPG)
Grenoble France
Follow ups
References