widgetdemo.html

来自「perl教程」· HTML 代码 · 共 97 行

HTML
97
字号
<?xml version="1.0" ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<!-- saved from url=(0017)http://localhost/ -->
<script language="JavaScript" src="../../displayToc.js"></script>
<script language="JavaScript" src="../../tocParas.js"></script>
<script language="JavaScript" src="../../tocTab.js"></script>
<link rel="stylesheet" type="text/css" href="../../scineplex.css">
<title>WidgetDemo - create a standard widget demonstration window.</title>
<link rel="stylesheet" href="../../Active.css" type="text/css" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<link rev="made" href="mailto:" />
</head>

<body>

<script>writelinks('__top__',2);</script>
<h1><a>WidgetDemo - create a standard widget demonstration window.</a></h1>
<p><a name="__index__"></a></p>

<!-- INDEX BEGIN -->

<ul>

	<li><a href="#name">NAME</a></li>
	<li><a href="#synopsis">SYNOPSIS</a></li>
	<li><a href="#description">DESCRIPTION</a></li>
	<li><a href="#author">AUTHOR</a></li>
	<li><a href="#history">HISTORY</a></li>
	<li><a href="#copyright">COPYRIGHT</a></li>
</ul>
<!-- INDEX END -->

<hr />
<p>
</p>
<h1><a name="name">NAME</a></h1>
<p><code>WidgetDemo()</code> - create a standard widget demonstration window.</p>
<p>
</p>
<hr />
<h1><a name="synopsis">SYNOPSIS</a></h1>
<pre>
 <span class="keyword">use</span> <span class="variable">WidgetDemo</span><span class="operator">;</span>
 <span class="keyword">my</span> <span class="variable">$TOP</span> <span class="operator">=</span> <span class="variable">$MW</span><span class="operator">-&gt;</span><span class="variable">WidgetDemo</span><span class="operator">(</span>
     <span class="string">-name</span>             <span class="operator">=&gt;</span> <span class="variable">$demo</span><span class="operator">,</span>
     <span class="string">-text</span>             <span class="operator">=&gt;</span> <span class="string">'Learn how to write a widget demonstration!'</span><span class="operator">,</span>
     <span class="string">-title</span>            <span class="operator">=&gt;</span> <span class="string">'WidgetDemo Demonstration'</span><span class="operator">,</span>
     <span class="string">-iconname</span>         <span class="operator">=&gt;</span> <span class="string">'WidgetDemo'</span><span class="operator">,</span>
     <span class="string">-geometry_manager</span> <span class="operator">=&gt;</span> <span class="string">'grid'</span><span class="operator">,</span>
     <span class="string">-font</span>             <span class="operator">=&gt;</span> <span class="variable">$FONT</span><span class="operator">,</span>
 <span class="operator">);</span>
</pre>
<p>
</p>
<hr />
<h1><a name="description">DESCRIPTION</a></h1>
<p>This constructor builds a standard widget demonstration window, composed of
three frames.  The top frame contains descriptive demonstration text.  The
bottom frame contains the &quot;Dismiss&quot; and &quot;See Code&quot; buttons.  The middle frame
is demonstration container, which came be managed by either the pack or grid
geometry manager.</p>
<p>The -text attribute is supplied to a Label widget, which is left-adjusted
with -wraplength set to 4 inches.  If you require different specifications
then pass an array to -text; the first element is the text string and
the remaining array elements are standard Label widget attributes - WidgetDemo
will rearrange things as required..</p>
<pre>
    -text =&gt; ['Hello World!', qw/-wraplength 6i/],</pre>
<p>
</p>
<hr />
<h1><a name="author">AUTHOR</a></h1>
<p>Steve Lidie &lt;<a href="mailto:Stephen.O.Lidie@Lehigh.EDU">Stephen.O.Lidie@Lehigh.EDU</a>&gt;</p>
<p>
</p>
<hr />
<h1><a name="history">HISTORY</a></h1>
<p><a href="mailto:lusol@Lehigh.EDU,">lusol@Lehigh.EDU,</a> LUCC, 97/02/11
<a href="mailto:lusol@Lehigh.EDU,">lusol@Lehigh.EDU,</a> LUCC, 97/06/07
<a href="mailto:Stephen.O.Lidie@Lehigh.EDU,">Stephen.O.Lidie@Lehigh.EDU,</a> LUCC, 97/06/07
 . Add <code>Delegates()</code> call that obviates the need for Top().  Many thanks to
   Achim Bohnet for this patch.
 . Fix -title so that it works.</p>
<p>
</p>
<hr />
<h1><a name="copyright">COPYRIGHT</a></h1>
<p>Copyright (C) 1997 - 1998 Stephen O. Lidie. All rights reserved.</p>
<p>This program is free software; you can redistribute it and/or modify it under
the same terms as Perl itself.</p>

</body>

</html>

⌨️ 快捷键说明

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