source: MML/trunk/machine/SOLEIL/common/toolbox/GUILayout/layoutHelp/User guide4_1.html @ 4

Last change on this file since 4 was 4, checked in by zhangj, 10 years ago

Initial import--MML version from SOLEIL@2013

File size: 4.6 KB
Line 
1<html xmlns:saxon="http://icl.com/saxon">
2   <head>
3      <link rel="stylesheet" type="text/css" href="doc.css"/>
4      <link rel="stylesheet" type="text/css" href=""/>
5      <meta author="The MathWorks Ltd."/>
6      <meta copyright="2011 The MathWorks Ltd."/>
7      <title>Setting defaults for one window</title>
8   </head>
9
10   
11    <body>
12      <table class="header" width="100%" border="0" cellspacing="0" cellpadding="0">
13         <tr>
14            <td bgcolor="#e4f0f8"><A href="User guide.html"><font face="Arial" bgcolor="#e4f0f8" size="+0" underline="0" color="#000000"><b>User guide</b></font></A></td>
15            <td width="36" bgcolor="#e4f0f8"><A HREF="User guide4.html"><IMG SRC="Images/leftarrow.png" BORDER="0" ALT="previous page"/></A><A HREF="User guide4_2.html"><IMG SRC="Images/rightarrow.png" BORDER="0" ALT="next page"/></A></td>
16         </tr>
17      </table>
18   
19
20      <br clear="all"/>
21         
22      <h2>4.1: Setting defaults for one window&nbsp;<a href="User guide4.html"><img src="Images/uparrow.png" border="0" align="top" alt="Go back up one level"/></a></h2>
23     
24            <p>The usual use of defaults is to modify the colors, fonts or
25                other settings used for a particular application window. The defaults
26            are therefore changed on the figure object using the <a href="uiextras.set.html"><code class="FUNCTION">uiextras.set</code></a> function.</p>
27        <p>The example below sets new defaults for panel title-bar color and font
28    on the window before two panels are added.</p>
29            <example>
30                <pre style="background-color: #eeeeff; margin-left: 20px; margin-right: 20px"><font color="#000011">f = <a href="matlab:doc figure"><code class="FUNCTION">figure</code></a>();
31<a href="uiextras.set.html"><code class="FUNCTION">uiextras.set</code></a>( f, <code class="STRING">'DefaultHBoxBackgroundColor'</code>, [0.3 0.3 0.3] );
32<a href="uiextras.set.html"><code class="FUNCTION">uiextras.set</code></a>( f, <code class="STRING">'DefaultBoxPanelTitleColor'</code>, <code class="STRING">'y'</code> );
33<a href="uiextras.set.html"><code class="FUNCTION">uiextras.set</code></a>( f, <code class="STRING">'DefaultBoxPanelFontSize'</code>, 16 );
34h = <a href="uiextras.HBox.html"><code class="FUNCTION">uiextras.HBox</code></a>( <code class="STRING">'Parent'</code>, f, <code class="STRING">'Padding'</code>, 10, <code class="STRING">'Spacing'</code>, 10 );
35p1 = <a href="uiextras.BoxPanel.html"><code class="FUNCTION">uiextras.BoxPanel</code></a>( <code class="STRING">'Parent'</code>, h, <code class="STRING">'Title'</code>, <code class="STRING">'Panel 1'</code> );
36p2 = <a href="uiextras.BoxPanel.html"><code class="FUNCTION">uiextras.BoxPanel</code></a>( <code class="STRING">'Parent'</code>, h, <code class="STRING">'Title'</code>, <code class="STRING">'Panel 2'</code> );</font></pre>
37            <p style="background-color: #ddddee; margin-left: 20px; margin-right: 20px"><font color="#000022"><center><img src="Images/DefaultsFigure.png"/></center></font></p>
38            </example>
39       
40     
41      <br clear="ALL"/>
42      <table class="footer" width="100%" border="0" cellspacing="0" cellpadding="0">
43         <tr>
44            <td width="18" height="15" bgcolor="#e4f0f8" align="left"><a href="User guide4.html"><img src="images/leftarrow.png" border="0" alt="previous page"/></a></td>
45            <td width="40%" height="15" bgcolor="#e4f0f8" align="left"><a href="User guide4.html"><font face="arial" bgcolor="#e4f0f8" size="normal" underline="0" color="#000000">Using property defaults</font></a></td>
46            <td width="20%" height="15" bgcolor="#e4f0f8" align="center"><a href="index.html"><font face="arial" bgcolor="#e4f0f8" size="normal" underline="0" color="#000000">[Top]</font></a></td>
47            <td width="40%" height="15" bgcolor="#e4f0f8" align="right"><a href="User guide4_2.html"><font face="arial" bgcolor="#e4f0f8" size="normal" underline="0" color="#000000">Setting defaults for all windows</font></a></td>
48            <td width="18" height="15" bgcolor="#e4f0f8" align="right"><a href="User guide4_2.html"><img src="images/rightarrow.png" border="0" alt="next page"/></a></td>
49         </tr>
50      </table>
51      <font face="Arial" bgcolor="#e4f0f8" size="normal" underline="0" color="#000000">&copy; 2011 The MathWorks Ltd</font>
52      <TT>&#149; </TT><a href="matlab: helpview([matlabroot,'/license.txt'])">Terms of Use</a>
53      <TT>&#149; </TT><a href="matlab: helpview([matlabroot,'/patents.txt'])">Patents</a>
54      <TT>&#149; </TT><a href="matlab: helpview([matlabroot,'/trademarks.txt'])">Trademarks</a>
55   
56   </body>
57</html>
58       
Note: See TracBrowser for help on using the repository browser.