Canola
0.8.D001
|
#include <image.h>
Public Types | |
typedef boost::shared_ptr < program_card_functor_image > | pointer |
Public Member Functions | |
virtual | ~program_card_functor_image () |
void | set_disassemble (bool value) |
Static Public Member Functions | |
static pointer | factory (const std::string &filename) |
Protected Member Functions | |
program_card_functor_image () | |
void | draw (const Cairo::RefPtr< Cairo::Context > &cr, const unsigned char *data, size_t data_size) |
void | draw_envelope (const Cairo::RefPtr< Cairo::Context > &cr) |
void | set_position (int card_num, int card_count) |
void | set_title (const std::string &text) |
void | set_arrow (bool value) |
void | set_color (const std::string &text) |
void | set_perforations (bool value) |
void | set_trim_corners (bool value) |
void | set_style (const std::string &text) |
virtual void | set_sfj_list (const std::string &text) |
virtual void | set_fj_list (const std::string &text) |
virtual void | set_memory_list (const std::string &text) |
virtual void | set_steps (int value) |
Private Types | |
enum | style_t { style_aus, style_ibm, style_blank } |
Private Member Functions | |
void | outline (const Cairo::RefPtr< Cairo::Context > &cr) |
program_card_functor_image (const program_card_functor_image &rhs) | |
program_card_functor_image & | operator= (const program_card_functor_image &rhs) |
Private Attributes | |
bool | trim_corners |
bool | perforations |
bool | disassemble |
bool | arrow |
int | card_num |
int | card_count |
std::string | color |
std::string | title |
style_t | style |
std::string | sfj_list |
unsigned | accuracy |
unsigned | step_count |
std::string | fj_list |
std::string | memory_list |
The program_card_functor class is used to represent the processing required to draw Canola 1614P program card images.
typedef boost::shared_ptr<program_card_functor_image> program_card_functor_image::pointer |
enum program_card_functor_image::style_t [private] |
program_card_functor_image::~program_card_functor_image | ( | ) | [virtual] |
program_card_functor_image::program_card_functor_image | ( | ) | [protected] |
program_card_functor_image::program_card_functor_image | ( | const program_card_functor_image & | rhs | ) | [private] |
The copy constructor. Do not use.
rhs | The right hand side of the initialization. |
void program_card_functor_image::draw | ( | const Cairo::RefPtr< Cairo::Context > & | cr, |
const unsigned char * | data, | ||
size_t | data_size | ||
) | [protected] |
The draw method is used to draw an image of a program card into the given drawing context. Because Cairo has numerous drawing surfaces, this allows card images to be PNG file, or post script, or Gtk windows, etc.
cr | The cairo graphics context to draw on. |
data | The program data to be drawn on the card image |
data_size | The length of the program to be drawn. |
void program_card_functor_image::draw_envelope | ( | const Cairo::RefPtr< Cairo::Context > & | cr | ) | [protected] |
program_card_functor_image::pointer program_card_functor_image::factory | ( | const std::string & | filename | ) | [static] |
The factory class method is used to create a functor suitable for use drawing images of programs cards. The file extension of the filename is examplined, for things like ".png" or ".pdf", etc.
filename | the name of the file to be written. |
Definition at line 44 of file factory.cc.
program_card_functor_image& program_card_functor_image::operator= | ( | const program_card_functor_image & | rhs | ) | [private] |
The assignment operator. Do not use.
rhs | The right hand side of the assignment. |
void program_card_functor_image::outline | ( | const Cairo::RefPtr< Cairo::Context > & | cr | ) | [private] |
void program_card_functor_image::set_arrow | ( | bool | value | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_color | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_disassemble | ( | bool | value | ) | [virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_fj_list | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_memory_list | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_perforations | ( | bool | value | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_position | ( | int | card_num, |
int | card_count | ||
) | [protected] |
void program_card_functor_image::set_sfj_list | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_steps | ( | int | value | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_style | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_title | ( | const std::string & | text | ) | [protected, virtual] |
Reimplemented from program_card_functor.
void program_card_functor_image::set_trim_corners | ( | bool | value | ) | [protected, virtual] |
Reimplemented from program_card_functor.
unsigned program_card_functor_image::accuracy [private] |
bool program_card_functor_image::arrow [private] |
int program_card_functor_image::card_count [private] |
int program_card_functor_image::card_num [private] |
std::string program_card_functor_image::color [private] |
bool program_card_functor_image::disassemble [private] |
std::string program_card_functor_image::fj_list [private] |
std::string program_card_functor_image::memory_list [private] |
bool program_card_functor_image::perforations [private] |
std::string program_card_functor_image::sfj_list [private] |
unsigned program_card_functor_image::step_count [private] |
style_t program_card_functor_image::style [private] |
std::string program_card_functor_image::title [private] |
bool program_card_functor_image::trim_corners [private] |