⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 right10-3.htm

📁 Visual C++面向对象程序设计教程(配套习题资源)
💻 HTM
字号:
<html>

<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>第 10 章</title>
<base target="rbottom">
<style>
<!--
.右标题   { font-size: 10pt; color: #000080; text-indent: 0; margin: 0 }
.右内容   { font-size: 10pt; text-align: left; text-indent: 0; line-height: 100%; margin: 
               0 }
-->
</style>
</head>

<body>

<p style="line-height: 100%; margin-top: 0; margin-bottom: 0"> </p>
<p style="line-height: 100%; margin-top: 0; margin-bottom: 0"><span style="position: absolute; left: 4; top: -8"><img border="0" src="1.gif" width="63" height="70"></span></p>
<p style="line-height: 100%; margin-top: 0; margin-bottom: 0">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p>
<p style="line-height: 100%; text-indent: 0; margin: 0" class="右标题" align="left">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;                                                           
&nbsp;&nbsp;&nbsp; <span style="background-color: #CCFF99">第 10 章</span><span style="background-color: #CCFF99">&nbsp;                                                  
</span>&gt;<span style="background-color: #CCFF99"> 第 </span><span style="background-color: #CCFF99">3 
节 </span>&gt;<span style="background-color: #CCFF99"> 10.3  
菜单编辑器的使用</span></p>                
<hr color="#008000" size="1">

<p style="line-height: 100%; text-indent: 0; margin: 0" align="left"><font LANG="ZH-CN" size="2">1.菜单及菜单项的创建</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">(1)  
在菜单栏上创建新菜单</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><span lang="EN-US" style="mso-bidi-font-size: 10.0pt; mso-fareast-font-family: 宋体; mso-font-kerning: 10.5pt; mso-ansi-language: EN-US; mso-fareast-language: ZH-CN; mso-bidi-language: AR-SA"><font size="2"><!--[if gte vml 1]><v:shapetype id="_x0000_t75" coordsize="21600,21600"
 o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe" filled="f"
 stroked="f">
 <v:stroke joinstyle="miter"/>
 <v:formulas>
  <v:f eqn="if lineDrawn pixelLineWidth 0"/>
  <v:f eqn="sum @0 1 0"/>
  <v:f eqn="sum 0 0 @1"/>
  <v:f eqn="prod @2 1 2"/>
  <v:f eqn="prod @3 21600 pixelWidth"/>
  <v:f eqn="prod @3 21600 pixelHeight"/>
  <v:f eqn="sum @0 0 1"/>
  <v:f eqn="prod @6 1 2"/>
  <v:f eqn="prod @7 21600 pixelWidth"/>
  <v:f eqn="sum @8 21600 0"/>
  <v:f eqn="prod @7 21600 pixelHeight"/>
  <v:f eqn="sum @10 21600 0"/>
 </v:formulas>
 <v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect"/>
 <o:lock v:ext="edit" aspectratio="t"/>
</v:shapetype><v:shape id="_x0000_i1025" type="#_x0000_t75" style='width:195pt;
 height:120pt'>
 <v:imagedata src="file:///C:/DOCUME~1/y/LOCALS~1/Temp/msoclip1/01/clip_image001.png"
  o:title=""/>
</v:shape><![endif]-->
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <img src="right118.jpg" v:shapes="_x0000_i1025" width="260" height="160"><span style="position: absolute; left: 383; top: 113"><img border="0" src="right119.gif" width="41" height="18"></span><span style="position: absolute; left: 383; top: 151"><img border="0" src="right120.gif" width="41" height="18"></span><span style="position: absolute; left: 384; top: 182"><img border="0" src="right121.gif" width="61" height="18"></span><span style="position: absolute; left: 262; top: 123"><img border="0" src="right122.gif" width="117" height="2"></span><span style="position: absolute; left: 164; top: 155"><img border="0" src="right123.gif" width="216" height="2"></span><span style="position: absolute; left: 229; top: 187"><img border="0" src="right124.gif" width="151" height="2"></span></font></span></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">创建一个主菜单的步骤如下:</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">①</font> 
<font LANG="ZH-CN">在资源文件中选中菜单资源,打开菜单编辑器。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">②</font> 
<font LANG="ZH-CN">双击需要增加菜单项的空白方框,弹出如图所示的“</font>Menu  
Item Properties<font LANG="ZH-CN">”对话框。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><span lang="EN-US" style="mso-bidi-font-size: 10.0pt; mso-fareast-font-family: 宋体; mso-font-kerning: 10.5pt; mso-ansi-language: EN-US; mso-fareast-language: ZH-CN; mso-bidi-language: AR-SA">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  
<img src="right125.jpg" v:shapes="_x0000_i1025" width="308" height="109"></span></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">③</font> 
<font LANG="ZH-CN">在“</font>Caption<font LANG="ZH-CN">”文本框中输入菜单名,例如“文件”。如果用户希望使用〈</font>Alt<font LANG="ZH-CN">〉</font>+<font LANG="ZH-CN">“字母”键选中菜单项,可以使用“</font>&amp;<font LANG="ZH-CN">”即可,例如“文件</font>(&amp;F)<font LANG="ZH-CN">”,菜单的显示形式为“文件</font>(<u>F</u>)<font LANG="ZH-CN">”。</font></font></p> 
<p ALIGN="left" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2">   
<span lang="EN-US" style="mso-bidi-font-size: 10.0pt; mso-fareast-font-family: 宋体; mso-font-kerning: 10.5pt; mso-ansi-language: EN-US; mso-fareast-language: ZH-CN; mso-bidi-language: AR-SA"><!--[if gte vml 1]><v:shapetype id="_x0000_t75" coordsize="21600,21600"
 o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe" filled="f"
 stroked="f">
 <v:stroke joinstyle="miter"/>
 <v:formulas>
  <v:f eqn="if lineDrawn pixelLineWidth 0"/>
  <v:f eqn="sum @0 1 0"/>
  <v:f eqn="sum 0 0 @1"/>
  <v:f eqn="prod @2 1 2"/>
  <v:f eqn="prod @3 21600 pixelWidth"/>
  <v:f eqn="prod @3 21600 pixelHeight"/>
  <v:f eqn="sum @0 0 1"/>
  <v:f eqn="prod @6 1 2"/>
  <v:f eqn="prod @7 21600 pixelWidth"/>
  <v:f eqn="sum @8 21600 0"/>
  <v:f eqn="prod @7 21600 pixelHeight"/>
  <v:f eqn="sum @10 21600 0"/>
 </v:formulas>
 <v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect"/>
 <o:lock v:ext="edit" aspectratio="t"/>
</v:shapetype><v:shape id="_x0000_i1025" type="#_x0000_t75" style='width:231pt;
 height:81.75pt'>
 <v:imagedata src="file:///C:/DOCUME~1/y/LOCALS~1/Temp/msoclip1/01/clip_image001.png"
  o:title=""/>
</v:shape><![endif]-->
</span>&nbsp;</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font lang="ZH-CN" size="2">(</font><font LANG="ZH-CN" size="2">2)  
创建新菜单项</font></p>
<font SIZE="3" COLOR="#ff0000">
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"></font><font size="2"><font LANG="ZH-CN">步骤和在菜单栏中创建一个新的菜单相同,注意输入</font>ID<font LANG="ZH-CN">和不能选中</font>Pop-up<font LANG="ZH-CN">选项。</font></font></p>
<p ALIGN="justify" style="line-height: 100%; margin-top: 10; margin-bottom: 0"><font LANG="ZH-CN" size="2">(3)  
创建级联子菜单</font></p>
<font SIZE="3" COLOR="#ff0000">
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"></font><font size="2"><font LANG="ZH-CN">步骤和在菜单栏中创建一个新的菜单相同,注意选中</font>Pop-up<font LANG="ZH-CN">选项。</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"> </p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2">2.  
<font LANG="ZH-CN">菜单及菜单项的移动和复制</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">(1)  
用菜单命令来完成</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">(2)  
用拖拉方式完成</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"> </p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2">3.  
<font LANG="ZH-CN">定义菜单项加速键</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">定义加速键的格式为:</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">菜单名</font>+<font LANG="ZH-CN">转义字符(</font>\&amp;<font LANG="ZH-CN">)</font>+<font LANG="ZH-CN">修改键名(</font>Ctrl<font LANG="ZH-CN">、</font>Alt<font LANG="ZH-CN">或</font>Shift<font LANG="ZH-CN">等)</font>+<font LANG="ZH-CN">附加键名</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2">例如<font LANG="ZH-CN">,撤消菜单的“</font>Caption<font LANG="ZH-CN">”框中需要输入“撤消</font>(&amp;U)&nbsp;&nbsp;  
\&amp;Ctrl+Z<font LANG="ZH-CN">”,那么撤消菜单的快捷键是〈</font>Alt<font LANG="ZH-CN">〉</font>+<font LANG="ZH-CN">〈</font>U<font LANG="ZH-CN">〉,加速键为〈</font>Ctrl<font LANG="ZH-CN">〉</font>+<font LANG="ZH-CN">〈</font>Z<font LANG="ZH-CN">〉。</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"> </p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2">4.  
<font LANG="ZH-CN">创建右键菜单</font></font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font LANG="ZH-CN" size="2">创建右键菜单的步骤如下:</font></p>
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">①</font> 
<font LANG="ZH-CN">用一个空标题创建一个菜单栏。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">②</font> 
<font LANG="ZH-CN">在标题框中暂时输入一个名称。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">③</font> 
<font LANG="ZH-CN">移动到下一个菜单项中,激活相应的属性对话框,输入有关标识符、标题及其他信息。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">④</font> 
<font LANG="ZH-CN">删除开始暂时输入的菜单名称,使其为空,目的是让右键菜单没有父菜单项。</font></font></p> 
<p ALIGN="JUSTIFY" style="line-height: 100%; margin-top: 0; margin-bottom: 0"><font size="2"><font LANG="ZH-CN">⑤</font> 
<font LANG="ZH-CN">保存该菜单资源。</font></font></p> 
<p style="line-height: 100%; text-indent: 0; margin: 0" class="右标题" align="left"> </p>

<hr size="1" color="#008000">
<p style="line-height: 100%; margin-top: 0; margin-bottom: 0"> </p>            

<p style="line-height: 100%; margin-top: 0; margin-bottom: 0">&nbsp;&nbsp; <span style="position: absolute; left: 23; top: 876"><a href="right10-2.htm" target="_self"><img border="0" src="rightd1.gif" width="113" height="70"></a></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;                                 
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="position: absolute; left: 503; top: 877"><a href="right10-4.htm" target="_self"><img border="0" src="rightd2.gif" width="124" height="63"></a></span></p>                    

</body>

</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -