AddOption.3
上传用户:rrhhcc
上传日期:2015-12-11
资源大小:54129k
文件大小:2k
- '"
- '" Copyright (c) 1998-2000 by Scriptics Corporation.
- '" All rights reserved.
- '"
- '" RCS: @(#) $Id: AddOption.3,v 1.2 2002/01/25 21:09:36 dgp Exp $
- '"
- '"
- .so man.macros
- .TH Tk_AddOption 3 "" Tk "Tk Library Procedures"
- .BS
- .SH NAME
- Tk_AddOption - Add an option to the option database
- .SH SYNOPSIS
- .nf
- fB#include <tk.h>fR
- .sp
- void
- fBTk_AddOptionfR(fItkwin, name, value, priorityfR)
- .SH ARGUMENTS
- .AP Tk_Window tkwin in
- Token for window.
- .AP "CONST char" *name in
- Multi-element name of option.
- .AP "CONST char" *value in
- Value of option.
- .AP int priority in
- Overall priority level to use for option.
- .BE
- .SH DESCRIPTION
- .PP
- This procedure is invoked to add an option to the database
- associated with fItkwinfR's main window. fINamefR
- contains the option being specified and consists of names and/or
- classes separated by asterisks or dots, in the usual X format.
- fIValuefR contains the text string to associate with fInamefR;
- this value will be returned in calls to fBTk_GetOptionfR.
- fIPriorityfR specifies the priority of the value; when options are
- queried using fBTk_GetOptionfR, the value with the highest priority
- is returned. fIPriorityfR must be between 0 and TK_MAX_PRIO. Some
- common priority values are:
- .TP
- 20
- Used for default values hard-coded into widgets.
- .TP
- 40
- Used for options specified in application-specific startup files.
- .TP
- 60
- Used for options specified in user-specific defaults files, such as
- fB.XdefaultsfR, resource databases loaded into the X server, or
- user-specific startup files.
- .TP
- 80
- Used for options specified interactively after the application starts
- running.
- .PP
- .SH KEYWORDS
- class, name, option, add