[Scilab-users] createWindow and uicontrol

Antoine Monmayrant antoine.monmayrant at laas.fr
Tue Jun 3 08:53:10 CEST 2014


On 06/02/2014 07:16 PM, Claus Futtrup wrote:
> Hi there
>
> My prevoius email didn't get a really good answer, so I try again - to 
> get partially a good answer:
>
> f = createWindow();
>
> The new method probably has its advantages, but the Scilab manual 
> doesn't really explain... can anybody explain to me?
>
> Can you use the same uicontrol commands with both methods?

Yes, both methods are almost identical.
You can see that by looking at the source code of createWindow.
Just type 'edit createWindow':

function f = createWindow()
     f = figure( ...
     "dockable", "off", ...
     "infobar_visible", "off", ...
     "toolbar_visible", "off", ...
     "menubar_visible", "off", ...
     "default_axes", "off");
endfunction

So createWindow is just a wrapper around figure, with different default 
values.

> (can I use examples found on the internet using "figure" and just 
> replace figure with createWindow?).
>
> It seems to me that the examples in the createWindow gives uicontrol 
> some inputs named "units" - "normalized" - etc. - which are not 
> present when looking at old figure() examples.
>
> My next question will be, how do I create a uicontrol which accepts a 
> string input (as I need 2 of those). The uicontrol documentation says 
> the "Edit" style will do that, but how?
Have a look at the Demos->Gui->Uicontrols1 or Uicontrols2 : there are 
text input uicontrols.
Click on the  'view code' menu to see what's under the hood.

Hope it helps,

Antoine
>
> /Claus
>
> ---
> This email is free from viruses and malware because avast! Antivirus 
> protection is active.
> http://www.avast.com
>
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users
>



More information about the users mailing list