77 lines
2.4 KiB

'\" JPEG support
'\" Color=Yellow
.so STk-man.macros
.TH jpeg n 3.2 STk "Tk Built-In Commands"
'\" Note: do not modify the .SH NAME line immediately below!
jpeg \- Create color images from JPEG files.
(\fBimage 'create 'jpeg \fR?\fIname\fR? ?\fIoptions\fR?)
JPG is a popular image file format for storing images.
The \fBjpeg\fR image type can be used to create color images using
JPEG files (aka \fI.jpg.\fR files).
Like all images, jpegs are created using the \fBimage create\fR
command. Jpeg images support the following \fIoptions\fR:
\fB\:file \fIname\fR
\fIname\fR gives the name of a file whose contents define the source
When a jpeg image is created, Tk also creates a new procedure whose
name is the same as the image. This procedure may be used to invoke
various operations on the image. It has the following general form:
(\fIimageName option \fR?\fIarg arg ...\fR?)
\fIOption\fR and the \fIarg\fRs
determine the exact behavior of the procedure. The following
commands are possible for jpeg images:
(\fIimageName \fB'cget\fR \fIoption\fR)
Returns the current value of the configuration option given by
\fIoption\fR. \fIOption\fR may have any of the values accepted by the
\fBimage create jpeg\fR command.
(\fIimageName \fB'configure\fR ?\fIoption\fR? ?\fIvalue option value ...\fR?)
Query or modify the configuration options for the image. If no
\fIoption\fR is specified, returns a list describing all of the
available options for \fIimageName\fR (see \fBTk_ConfigureInfo\fR for
information on the format of this list). If \fIoption\fR is specified
with no \fIvalue\fR, then the command returns a list describing the
one named option (this list will be identical to the corresponding
sublist of the value returned if no \fIoption\fR is specified). If
one or more \fIoption\-value\fR pairs are specified, then the command
modifies the given option(s) to have the given value(s); in this case
the command returns an empty string. \fIOption\fR may have any of the
values accepted by the \fBimage create jpeg\fR command.
Use \fB(require "jpeg")\fR to initialize the jpeg package.
This implementation of the jpeg image format was done
by Andrew Swan \fI<>\fR
bitmap, make-image, image, photo, pixmap