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

📄 c++ builder 程序设计实用教程 - 5_4_3 文件列表和文件过滤控件 - 张晋 - 17xie.htm

📁 已经消失的不易找到的C++ builder网络教程总结
💻 HTM
📖 第 1 页 / 共 4 页
字号:
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 76.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=102>
      <P class=a1><SPAN lang=EN-US>ParentFont</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 85.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=114>
      <P class=a1><SPAN lang=EN-US>PixelsPerInch</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: medium none; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 174.55pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid black .75pt; mso-border-left-alt: solid black .75pt" 
    width=233>
      <P class=a1><SPAN lang=EN-US>PopupMenu</SPAN></P></TD></TR>
  <TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes">
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 81.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid black .75pt; mso-border-right-alt: solid black .75pt" 
    width=108>
      <P class=a1><SPAN lang=EN-US>Position</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 76.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=102>
      <P class=a1><SPAN lang=EN-US>PrintScale</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 85.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=114>
      <P class=a1><SPAN lang=EN-US>Scaled</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: medium none; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 174.55pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid black .75pt; mso-border-left-alt: solid black .75pt" 
    width=233>
      <P class=a1><SPAN lang=EN-US>ShowHint</SPAN></P></TD></TR>
  <TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes">
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 81.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid black .75pt; mso-border-right-alt: solid black .75pt" 
    width=108>
      <P class=a1><SPAN lang=EN-US>Tag</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 76.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=102>
      <P class=a1><SPAN lang=EN-US>Top</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 85.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=114>
      <P class=a1><SPAN lang=EN-US>UseDockManager</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: medium none; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 174.55pt; PADDING-TOP: 0cm; BORDER-BOTTOM: black 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid black .75pt; mso-border-left-alt: solid black .75pt" 
    width=233>
      <P class=a1><SPAN lang=EN-US>VertScrollBar</SPAN></P></TD></TR>
  <TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes">
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 81.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: windowtext 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid windowtext 1.0pt; mso-border-right-alt: solid black .75pt" 
    width=108>
      <P class=a1><SPAN lang=EN-US>Visible</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 76.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: windowtext 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid windowtext 1.0pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=102>
      <P class=a1><SPAN lang=EN-US>Width</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 85.3pt; PADDING-TOP: 0cm; BORDER-BOTTOM: windowtext 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-bottom-alt: solid windowtext 1.0pt; mso-border-left-alt: solid black .75pt; mso-border-alt: solid black .75pt" 
    width=114>
      <P class=a1><SPAN lang=EN-US>WindowMenu</SPAN></P></TD>
    <TD 
    style="BORDER-RIGHT: medium none; PADDING-RIGHT: 5.4pt; BORDER-TOP: medium none; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0cm; BORDER-LEFT: medium none; WIDTH: 174.55pt; PADDING-TOP: 0cm; BORDER-BOTTOM: windowtext 1pt solid; mso-border-top-alt: solid black .75pt; mso-border-left-alt: solid black .75pt" 
    width=233>
      <P class=a1><SPAN 
lang=EN-US>WindowState</SPAN></P></TD></TR></TBODY></TABLE></DIV>
<P class=MsoNormalIndent><SPAN lang=EN-US>FilterComboBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件的属性在这里就不一一的加以介绍了,如果读者有什么不清楚的地方,请参考有关的参考手册,下面以一个示例来说明</SPAN><SPAN 
lang=EN-US>FilterComboBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件和它的属性的用法,另外还介绍了如何使</SPAN><SPAN 
lang=EN-US>FilterComboBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件与</SPAN><SPAN 
lang=EN-US>FileListBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件相互协调工作。制作示例程序的具体步骤如下所示:</SPAN></P>
<H4><SPAN lang=EN-US>1</SPAN><SPAN 
style="FONT-FAMILY: 楷体_GB2312; mso-ascii-font-family: 'Times New Roman'">.开始工作</SPAN></H4>
<P class=MsoNormalIndent><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">首先启动一个新的项目,选择菜单</SPAN><SPAN 
lang=EN-US>File</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">中的</SPAN><SPAN 
lang=EN-US>New Application</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">项,在</SPAN><SPAN 
lang=EN-US>CBuilder 5</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">的集成开发环境中就会弹出一个新建的窗体,选择</SPAN><SPAN 
lang=EN-US>FileListBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件和</SPAN><SPAN 
lang=EN-US>FilterComboBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件,并且把它们拖放到空白的窗体上,添加控件后的窗体如图</SPAN><SPAN 
lang=EN-US>5-14</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">所示。</SPAN></P>
<P class=a0><SPAN lang=EN-US><IMG height=193 
src="C++ Builder 程序设计实用教程 - 5_4_3 文件列表和文件过滤控件 - 张晋 - 17xie.files/4539515490.jpg" 
width=228 v:shapes="_x0000_i1025"></SPAN></P>
<P class=MsoCaption style="MARGIN: 0cm 0cm 0pt"><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">图</SPAN><SPAN 
lang=EN-US>5-14<SPAN style="mso-spacerun: yes">&nbsp; </SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">添加控件后的窗体</SPAN></P>
<H4><SPAN lang=EN-US>2</SPAN><SPAN 
style="FONT-FAMILY: 楷体_GB2312; mso-ascii-font-family: 'Times New Roman'">.设置控件属性</SPAN></H4>
<P class=MsoNormalIndent><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">在程序的设计阶段,用鼠标的左键单击</SPAN><SPAN 
lang=EN-US>FilterComboBox</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">控件属性列表中的</SPAN><SPAN 
lang=EN-US>Filter</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">属性设置框中的按钮</SPAN><SPAN 
lang=EN-US style="mso-font-kerning: 0pt; mso-no-proof: yes"><IMG height=15 
src="C++ Builder 程序设计实用教程 - 5_4_3 文件列表和文件过滤控件 - 张晋 - 17xie.files/fde55bed9b.jpg" 
width=17 v:shapes="_x0000_i1026"></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-font-kerning: 0pt; mso-no-proof: yes">,就会弹出一个如图</SPAN><SPAN 
lang=EN-US style="mso-font-kerning: 0pt; mso-no-proof: yes">5-15</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-font-kerning: 0pt; mso-no-proof: yes">所示的过滤器设置对话框,用户可以在其中设置文件显示的过滤器。</SPAN></P>
<P class=a0><SPAN lang=EN-US><IMG height=170 
src="C++ Builder 程序设计实用教程 - 5_4_3 文件列表和文件过滤控件 - 张晋 - 17xie.files/d9a032f432.jpg" 
width=254 v:shapes="_x0000_i1027"></SPAN></P>
<P class=MsoCaption><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">图</SPAN><SPAN 
lang=EN-US>5-15<SPAN style="mso-spacerun: yes">&nbsp; </SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">过滤器设置</SPAN></P>
<P class=MsoNormalIndent><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">在本程序中,过滤器的属性设置为</SPAN><SPAN 
lang=EN-US>All files (*.*)|*.*|Text files(*.txt)|*.txt|DLL file(*.dll)|*.dll|EXE 
file(*.exe)|*.exe</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">,也就是说,在程序的运行过程中,用户在显示文件类型上有</SPAN><SPAN 
lang=EN-US>4</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">种选择:</SPAN></P>
<P class=MsoNormal 
style="MARGIN-LEFT: 42.5pt; TEXT-INDENT: -21.25pt; tab-stops: list 21.25pt; mso-list: l0 level1 lfo1"><SPAN 
lang=EN-US 
style="FONT-FAMILY: Wingdings; mso-fareast-font-family: Wingdings; mso-bidi-font-family: Wingdings"><SPAN 
style="mso-list: Ignore">n<SPAN 
style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
</SPAN></SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">显示全部文件;</SPAN></P>
<P class=MsoNormal 
style="MARGIN-LEFT: 42.5pt; TEXT-INDENT: -21.25pt; tab-stops: list 21.25pt; mso-list: l0 level1 lfo1"><SPAN 
lang=EN-US 
style="FONT-FAMILY: Wingdings; mso-fareast-font-family: Wingdings; mso-bidi-font-family: Wingdings"><SPAN 
style="mso-list: Ignore">n<SPAN 
style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
</SPAN></SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">显示以</SPAN><SPAN 
lang=EN-US>*.txt</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">结尾的文本文件;</SPAN></P>
<P class=MsoNormal 
style="MARGIN-LEFT: 42.5pt; TEXT-INDENT: -21.25pt; tab-stops: list 21.25pt; mso-list: l0 level1 lfo1"><SPAN 
lang=EN-US 
style="FONT-FAMILY: Wingdings; mso-fareast-font-family: Wingdings; mso-bidi-font-family: Wingdings"><SPAN 
style="mso-list: Ignore">n<SPAN 
style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
</SPAN></SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">显示以</SPAN><SPAN 
lang=EN-US>*.dll</SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">结尾的动态链接库文件;</SPAN></P>
<P class=MsoNormal 
style="MARGIN-LEFT: 42.5pt; TEXT-INDENT: -21.25pt; tab-stops: list 21.25pt; mso-list: l0 level1 lfo1"><SPAN 
lang=EN-US 
style="FONT-FAMILY: Wingdings; mso-fareast-font-family: Wingdings; mso-bidi-font-family: Wingdings"><SPAN 
style="mso-list: Ignore">n<SPAN 
style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
</SPAN></SPAN></SPAN><SPAN 
style="FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'">显示以</SPAN><SPAN 

⌨️ 快捷键说明

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