On Wed, Aug 11, 2010 at 06:01:11AM +0000, Chris Morley wrote:
> Now to make gladevcp really useful , with Chris R's permission
> I would like to add about twenty line of code to touchy and touchy's
> hal_interface.
> and export an environment variable INI_DIR from scripts/emc
>
> this would allow touchy to check to see if there is a local copy of
> toughy.glade in
> the loading configs folder (INI_DIR) and call gladevcp_makepins to parse and
> make
> any found HAL widgets. If the touchy.glade file is not modified then touchy
> does not
> make any extra pins or look/act any different.
Hi Chris,
Thanks for your work on this and I'm very open to having part of
touchy be a customizable vcp. However I'm worried that letting the
user modify whatever he wants in glade is going to cause trouble and
break the existing functionality of touchy.
The python part of touchy makes a lot of assumptions about the glade
widgets, assumptions which will be broken if the widgets are modified
in certain ways. For instance this code to determine which tab is
presently showing (to determine what the cycle start button should
do):
self.hal.periodic(self.tab == 1) # MDI tab?
would be broken if someone adds a tab to the left of the MDI tab.
This is just an example I found - I'm sure it's not the only way
modifying the glade layout could subtly or overtly break the way
touchy works. Also touchy removes widgets and table rows/columns to
undisplay ABCUVW buttons and DRO lines that are not used by the
machine configuration. This is another way the python code
(unfortunately) has intimate knowledge and strict expectations about
the layout of the screens and it seems like it would be easy to break
if a user added or removed something from those tables.
Now on to my counter-idea:
With the way AXIS does vcp in mind (the user widgets adjacent to the
fixed widgets), I wonder if touchy could have a "User" tab. If there
was a touchy-vcp.glade file in the configuration, could touchy create
a User tab and add those glade widgets to it? Or maybe do like in
AXIS, where the user widgets are beside the fixed widgets?
Having the user working with just his own widgets in glade seems
really superior to having him working with all of the touchy layout,
which is kind of intricate.
I do not know if it's possible for a second glade file to be loaded
after the initial one - do you know about this?
Chris
------------------------------------------------------------------------------
This SF.net email is sponsored by
Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers