Ace::Graphics::GlyphFactory - Create Ace::Graphics::Glyphs
use Ace::Graphics::GlyphFactory; my $factory = Ace::Graphics::GlyphFactory($glyph_name,@options);
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.
This section describes the class and object methods for Ace::Graphics::GlyphFactory.
There is only one constructor, the new() method. It is ordinarily called by Ace::Graphics::Track, in the make_factory() subroutine.
The new() method creates a new factory object. The object will create glyphs of type $glyph_name, and using the options specified in @options. Generic options are described in Ace::Graphics::Panel, and specific options are described in each of the Ace::Graphics::Glyph::* manual pages. =back
Once a track is created, the following methods can be invoked:
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.
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.
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.
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' map_pt() method when performing the rendering.
Get or set the background color for the glyphs.
Get or set the fill color for the glyphs.
Get or set the font to use for rendering the glyph.
Get the color for the font (to set it, use fgcolor()). This is subtly different from fgcolor() itself, because it will never return a styled color, such as gdBrushed.
Get or set the panel that contains the GD::Image object used by this factory.
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.
Please report them.
Ace::Sequence, Ace::Sequence::Feature, Ace::Graphics::Panel, Ace::Graphics::Track, Ace::Graphics::Glyph
Lincoln Stein <lstein@cshl.org>.
Copyright (c) 2001 Cold Spring Harbor Laboratory
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.
1 POD Error
The following errors were encountered while parsing the POD:
You forgot a '=back' before '=head2'
To install Ace, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Ace
CPAN shell
perl -MCPAN -e shell install Ace
For more information on module installation, please visit the detailed CPAN module installation guide.