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

📄 0124-0125.html

📁 linux-unix130.linux.and.unix.ebooks130 linux and unix ebookslinuxLearning Linux - Collection of 12 E
💻 HTML
字号:
<HTML>



<HEAD>

<TITLE>Linux Complete Command Reference:User Commands:EarthWeb Inc.-</TITLE>

</HEAD>

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>

 -->




<!-- ISBN=0672311046 //-->

<!-- TITLE=Linux Complete Command Reference//-->

<!-- AUTHOR=Red Hat//-->

<!-- PUBLISHER=Macmillan Computer Publishing//-->

<!-- IMPRINT=Sams//-->

<!-- CHAPTER=01 //-->

<!-- PAGES=0001-0736 //-->

<!-- UNASSIGNED1 //-->

<!-- UNASSIGNED2 //-->



<P><CENTER>

<a href="0122-0123.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0126-0127.html">Next</A></CENTER></P>







<A NAME="PAGENUM-124"><P>Page 124</P></A>





<TABLE>



<TR><TD>

Command Area

</TD><TD>

This area contains several command buttons, described in the following list:

</TD></TR><TR><TD>

</TD><TD>

The Set Save File button allows the user to modify file that the resources will

be saved to. This button will bring up a dialog box that will ask you for a

filename; after the filename has been entered, either hit carriage-return or click on

the Okay button. To pop down the dialog box without changing the save file,

click the Cancel button.

</TD></TR><TR><TD>

</TD><TD>

The Save button will append the resource line already described to the end of

the current save file. If no save file has been set, the Set Save File dialog box will

be popped up to prompt the user for a filename.

</TD></TR><TR><TD>

</TD><TD>

The Apply button attempts to perform a

XtSetValues call on all widgets that match the resource line described earlier. The value specified is applied

directly to all matching widgets. This behavior is an attempt to give a dynamic feel to

the resource editor. Since this feature allows users to put an application in states

it may not be willing to handle, a hook has been provided to allow

specific applications to block these SetValues requests. (See &quot;Blocking

editres Requests,&quot; following).

</TD></TR><TR><TD>

</TD><TD>

Unfortunately, due to design constraints imposed on the widgets by the

X Toolkit and the Resource Manager, trying to coerce an inherently static

system into dynamic behavior can cause strange results. There is no guarantee that

the results of an apply will be the same as what will happen when you save the

value and restart the application. This functionality is provided to try to give you

a rough feel for what your changes will accomplish, and the results

obtained should be considered suspect at best. Having said

that, this is one of the neatest features of

editres, and I strongly suggest that you play with it, and see what

it can do.

</TD></TR><TR><TD>

</TD><TD>

The Save and Apply button combines the Save and Apply actions

described earlier into one button.

</TD></TR><TR><TD>

</TD><TD>

The Popdown Resource Box button will remove the resource box from

the display.

</TD></TR></TABLE>





<P><B>

BLOCKING editres REQUESTS

</B></P>



<P>The editres protocol has been built into the Athena Widget set. This allows all applications that are linked against

Xaw to be able to speak to the resource editor. Although this provides great flexibility, and is a useful tool, it can quite easily be

abused. It is therefore possible for any Xaw application to specify a value for the

editresBlock resource to keep editres from

divulging information about its internals, or to disable the

SetValues part of the protocol.

</P>



<P>editresBlock (Class Editresblock) specifies which type of blocking this application wishes to impose on the

editres protocol.

</P>



<P>The accepted values are as follows:</P>



<TABLE>



<TR><TD>

all

</TD><TD>

Block all requests.

</TD></TR><TR><TD>

setValues

</TD><TD>

Block all SetValues requests. As this is the only

editres request that actually modifies the application,

this is in effect stating that the application is read-only.

</TD></TR><TR><TD>

none

</TD><TD>

Allow all editres requests.

</TD></TR></TABLE>



<P>Remember that these resources are set on any

Xaw application, not editres. They allow individual applications to keep all

or some of the requests editres makes from ever succeeding. Of course,

editres is also an Xaw application, so it may also

be viewed and modified by editres (rather recursive, I know); these commands can be blocked by setting the

editresBlock resource on editres itself.

</P>



<P><B>

RESOURCES

</B></P>



<P>For editres, the available application resources are as follows:

</P>



<P>numFlashes (Class NumFlashes) specifies the number of times the widgets in the application will be flashed when the

Show Active Widgets command in invoked.

</P>



<A NAME="PAGENUM-125"><P>Page 125</P></A>





<P>

flashTime (Class FlashTime) specifies the mount of time between the flashes described in the preceding entry.

flashColor (Class flashColor) specifies the color used to flash application widgets. A bright color should be used that

will immediately draw your attention to the area being flashed, such as red or yellow.

saveResourcesFile (Class SaveResourcesFile) is the file the resource line will be append to when the Save button activated

in the resource box.

</P>



<P><B>

WIDGETS

</B></P>



<P>In order to specify resources, it is useful to know the hierarchy of the widgets that compose

editres. In the following notation, indentation indicates hierarchical structure. The widget class name is given first, followed by the widget

instance name.

</P>



<!-- CODE //-->

<PRE>

Editres editres

       Paned paned

             Box box

                    MenuButton commands

                        SimpleMenu menu

                        SmeBSB sendTree

                        SmeBSB refreshTree

                        SmeBSB dumpTreeToFile

                        SmeLine line SmeBSB getResourceList

                        SmeLine line

                        SmeBSB quit

                    MenuButton treeCommands

                        SimpleMenuumenu

                        SmeBSB showClientWidget

                        SmeBSB selectAll

                        SmeBSB unselectAll

                        SmeBSB invertAll

                        SmeLine line

                        SmeBSB selectChildren

                        SmeBSB selectParent

                        SmeBSB selectDescendants

                        SmeBSB selectAncestors

                        SmeLine line

                        SmeBSB showWidgetNames

                        SmeBSB showClassNames

                        SmeBSB showWidgetIDs

                        SmeBSB showWidgetWindows

                        SmeLine line

                        SmeBSB flashActiveWidgets

              Paned hPane

                    Panner panner

                    Label userMessage

                    Grip grip

              Porthole porthole

                    Tree tree

                          Toggle &lt;name of widget in application&gt;

                          .

                          .

                          .

                          TransientShell resourceBox

                          Paned pane

                          Label resourceLabel

                          Form namesAndClasses

                          Toggle dot

                          Toggle star

                          Toggle any

                          Toggle name







</PRE>

<!-- END CODE //-->









<P><CENTER>

<a href="0122-0123.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0126-0127.html">Next</A></CENTER></P>







</td>
</tr>
</table>

<!-- begin footer information -->







</body></html>

⌨️ 快捷键说明

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