📄 image.n
字号:
'\"'\" Copyright (c) 1994 The Regents of the University of California.'\" Copyright (c) 1994-1996 Sun Microsystems, Inc.'\"'\" See the file "license.terms" for information on usage and redistribution'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.'\" '\" SCCS: @(#) image.n 1.10 96/03/26 18:23:05'\" .so man.macros.TH image n 4.0 Tk "Tk Built-In Commands".BS'\" Note: do not modify the .SH NAME line immediately below!.SH NAMEimage \- Create and manipulate images.SH SYNOPSIS\fBimage\fR \fIoption \fR?\fIarg arg ...\fR?.BE.SH DESCRIPTION.PPThe \fBimage\fR command is used to create, delete, and query images.It can take several different forms, depending on the\fIoption\fR argument. The legal forms are:.TP\fBimage create \fItype \fR?\fIname\fR? ?\fIoption value ...\fR?Creates a new image and returns its name.\fItype\fR specifies the type of the image, which must be one ofthe types currently defined (e.g., \fBbitmap\fR).\fIname\fR specifies the name for the image; if it is omitted thenTk picks a name of the form \fBimage\fIx\fR, where \fIx\fR isan integer.There may be any number of \fIoption\fR\-\fIvalue\fR pairs,which provide configuration options for the new image.The legal set of options is defined separately for each imagetype; see below for details on the options for built-in image types.If an image already exists by the given name then it is replacedwith the new image and any instances of that image will redisplaywith the new contents..TP\fBimage delete \fR?\fIname name\fR ...?Deletes each of the named images and returns an empty string.If there are instances of the images displayed in widgets,the images won't actually be deleted until all of the instancesare released.However, the association between the instances and the imagemanager will be dropped.Existing instances will retain their sizes but redisplay asempty areas.If a deleted image is recreated with another call to \fBimage create\fR,the existing instances will use the new image..TP\fBimage height \fIname\fRReturns a decimal string giving the height of image \fIname\fRin pixels..TP\fBimage names\fRReturns a list containing the names of all existing images..TP\fBimage type \fIname\fRReturns the type of image \fIname\fR (the value of the \fItype\fRargument to \fBimage create\fR when the image was created)..TP\fBimage types\fRReturns a list whose elements are all of the valid image types(i.e., all of the values that may be supplied for the \fItype\fRargument to \fBimage create\fR)..TP\fBimage width \fIname\fRReturns a decimal string giving the width of image \fIname\fRin pixels..SH "BUILT-IN IMAGE TYPES".PPThe following image types are defined by Tk so they will be availablein any Tk application.Individual applications or extensions may define additional types..TP\fBbitmap\fREach pixel in the image displays a foreground color, a backgroundcolor, or nothing.See the \fBbitmap\fR manual entry for more information..TP\fBphoto\fRDisplays a variety of full-color images, using dithering toapproximate colors on displays with limited color capabilities.See the \fBphoto\fR manual entry for more information..SH KEYWORDSheight, image, types of images, width
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -