Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: jumping directly to uisetcolor "more color..." tab
Replies: 3   Last Post: Dec 2, 2012 4:23 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
orion216

Posts: 11
From: Netherlands
Registered: 9/24/07
jumping directly to uisetcolor "more color..." tab
Posted: Nov 29, 2012 6:01 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hi,

I am exploring uisetcolor. How can we set control such that when I press color selection button (such as the example below) the color picker opens automatically Swatches (or HSB, or RGB) tab under 'More Color...'. I dont want to use the default swatches which has limited colors, because then the user has to switch to More Color... every time, which make them annoyed/bored/lose patience with my experiment.

Thanks all.

function test
f=figure;
uicontrol('Parent',f,'Style', 'pushbutton',...
'Position', [0 0 130 30],'String','Color',...
'CallBack',@color_Callback);
actxcontrol('OWC.Spreadsheet.9', [150 150 300 300],f);
return

function color_Callback(hObject, eventdata, handles)
c1=get(gcf,'Color');
c = uisetcolor(c1, 'Entity color');
uicontrol(hObject);
disp('HALLO') ;
if sum(c1==c)<3
set(gcf,'Color',c);
end
return



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.