.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Ace::Graphics::GlyphFactory 3pm" .TH Ace::Graphics::GlyphFactory 3pm 2024-01-10 "perl v5.38.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME Ace::Graphics::GlyphFactory \- Create Ace::Graphics::Glyphs .SH SYNOPSIS .IX Header "SYNOPSIS" .Vb 1 \& use Ace::Graphics::GlyphFactory; \& \& my $factory = Ace::Graphics::GlyphFactory($glyph_name,@options); .Ve .SH DESCRIPTION .IX Header "DESCRIPTION" The Ace::Graphics::GlyphFactory class is used internally by Ace::Graphics::Track and Ace::Graphics::Glyph to hold the options pertaining to a set of related glyphs and creating them on demand. This class is not ordinarily useful to the end-developer. .SH METHODS .IX Header "METHODS" This section describes the class and object methods for Ace::Graphics::GlyphFactory. .SS CONSTRUCTORS .IX Subsection "CONSTRUCTORS" There is only one constructor, the \fBnew()\fR method. It is ordinarily called by Ace::Graphics::Track, in the \fBmake_factory()\fR subroutine. .ie n .IP "$factory = Ace::Graphics::GlyphFactory\->new($glyph_name,@options)" 4 .el .IP "\f(CW$factory\fR = Ace::Graphics::GlyphFactory\->new($glyph_name,@options)" 4 .IX Item "$factory = Ace::Graphics::GlyphFactory->new($glyph_name,@options)" The \fBnew()\fR method creates a new factory object. The object will create glyphs of type \f(CW$glyph_name\fR, and using the options specified in \&\f(CW@options\fR. Generic options are described in Ace::Graphics::Panel, and specific options are described in each of the Ace::Graphics::Glyph::* manual pages. =back .SS "OBJECT METHODS" .IX Subsection "OBJECT METHODS" Once a track is created, the following methods can be invoked: .ie n .IP "$glyph = $factory\->glyph($feature)" 4 .el .IP "\f(CW$glyph\fR = \f(CW$factory\fR\->glyph($feature)" 4 .IX Item "$glyph = $factory->glyph($feature)" Given a sequence feature, creates an Ace::Graphics::Glyph object to display it. The various attributes of the glyph are set from the options provided at factory creation time. .ie n .IP "$option = $factory\->option($option_name [,$new_option])" 4 .el .IP "\f(CW$option\fR = \f(CW$factory\fR\->option($option_name [,$new_option])" 4 .IX Item "$option = $factory->option($option_name [,$new_option])" Given an option name, returns its value. If a second argument is provided, sets the option to the new value and returns its previous one. .ie n .IP "$index = $factory\->fgcolor" 4 .el .IP "\f(CW$index\fR = \f(CW$factory\fR\->fgcolor" 4 .IX Item "$index = $factory->fgcolor" Returns the desired foreground color for the glyphs in the form of an GD::Image color index. This may be the one of the special colors gdBrushed and gdStyled. This is only useful while the enclosing Ace::Graphics::Panel object is rendering the object. In other contexts it returns undef. .ie n .IP "$scale = $factory\->scale([$scale])" 4 .el .IP "\f(CW$scale\fR = \f(CW$factory\fR\->scale([$scale])" 4 .IX Item "$scale = $factory->scale([$scale])" Get or set the scale, in pixels/bp, for the glyph. This is ordinarily set by the Ace::Graphics::Track object just prior to rendering, and called by each glyphs' \fBmap_pt()\fR method when performing the rendering. .ie n .IP "$color = $factory\->bgcolor([$color])" 4 .el .IP "\f(CW$color\fR = \f(CW$factory\fR\->bgcolor([$color])" 4 .IX Item "$color = $factory->bgcolor([$color])" Get or set the background color for the glyphs. .ie n .IP "$color = $factory\->fillcolor([$color])" 4 .el .IP "\f(CW$color\fR = \f(CW$factory\fR\->fillcolor([$color])" 4 .IX Item "$color = $factory->fillcolor([$color])" Get or set the fill color for the glyphs. .ie n .IP "$font = $factory\->font([$font])" 4 .el .IP "\f(CW$font\fR = \f(CW$factory\fR\->font([$font])" 4 .IX Item "$font = $factory->font([$font])" Get or set the font to use for rendering the glyph. .ie n .IP "$color = $factory\->fontcolor" 4 .el .IP "\f(CW$color\fR = \f(CW$factory\fR\->fontcolor" 4 .IX Item "$color = $factory->fontcolor" Get the color for the font (to set it, use \fBfgcolor()\fR). This is subtly different from \fBfgcolor()\fR itself, because it will never return a styled color, such as gdBrushed. .ie n .IP "$panel = $factory\->panel([$panel])" 4 .el .IP "\f(CW$panel\fR = \f(CW$factory\fR\->panel([$panel])" 4 .IX Item "$panel = $factory->panel([$panel])" Get or set the panel that contains the GD::Image object used by this factory. .ie n .IP "$index = $factory\->translate($color)" 4 .el .IP "\f(CW$index\fR = \f(CW$factory\fR\->translate($color)" 4 .IX Item "$index = $factory->translate($color)" .PD 0 .ie n .IP "@rgb = $factory\->rgb($index)" 4 .el .IP "\f(CW@rgb\fR = \f(CW$factory\fR\->rgb($index)" 4 .IX Item "@rgb = $factory->rgb($index)" .PD These are convenience procedures that are passed through to the enclosing Panel object and have the same effect as the like-named methods in that class. See Ace::Graphics::Panel. .SH BUGS .IX Header "BUGS" Please report them. .SH "SEE ALSO" .IX Header "SEE ALSO" Ace::Sequence, Ace::Sequence::Feature, Ace::Graphics::Panel, Ace::Graphics::Track, Ace::Graphics::Glyph .SH AUTHOR .IX Header "AUTHOR" Lincoln Stein . .PP Copyright (c) 2001 Cold Spring Harbor Laboratory .PP This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty. .SH "POD ERRORS" .IX Header "POD ERRORS" Hey! \fBThe above document had some coding errors, which are explained below:\fR .IP "Around line 191:" 4 .IX Item "Around line 191:" You forgot a '=back' before '=head2'