Graphic interfaces

Jean-Louis Auge Jean-Louis.Auge at grenoble.cnrs.fr
Tue Dec 28 17:09:19 CET 2010


Dear users,

I attempted to do a little program to change the label of a pushbutton 
but the result is was inconclusive.

Here the programm:

//Initialisation stage
clear all;
clc;
for i=0:100, close(i), end;


//to change the label of the button A
function [A_style]=changeA(B_style,A_style)
  A_style.String="B"
  disp("go through changeA")
endfunction;

//to change the label of the button B
function [B_style]=changeB(A_style)
  B_style.String="A"
  disp("go through changeB")
endfunction;


h=scf();
h.position=[0 0 1000 800];
A_style=uicontrol(h,"style", "pushbutton");
A_style.Units="normalized";
A_style.Position = [0 0.95 0.2 0.05];
A_style.BackgroundColor="1|0|1";
A_style.Fontsize=20;
A_style.String = "A";
A_style.Callback="changeB";

B_style=uicontrol(h,"style", "pushbutton");
B_style.Units="normalized";
B_style.Position = [0 0 0.2 0.05];
B_style.BackgroundColor="1|0|1";
B_style.Fontsize=20;
B_style.String = "B";
B_style.Callback="changeA";


I wanted change the label of  the pressbutton A pushing the button B and 
vice versa.
The result is inconclusive.

Does somebody meet this case in this development.

Moreover, do you know websites where graphic interfaces documentations 
are given? I did not find many comments about the subject.
Is Scilab often use to develop interface graphics?

Best regards,

JL.






More information about the users mailing list