Sanko Robinson > FLTK > FLTK::NamedStyle

Download:
FLTK-0.532009.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: 0.532006   Source  

NAME ^

FLTK::NamedStyle - Simulate themes (by name) for the Fast Light Toolkit

Description ^

Typically a widget class will define a single NamedStyle that is used by all instances of that widget. A "theme" can locate this structure by looking it up by name (using the find() method) and then change it to change the appearance of all widgets of that class.

The reason a string name is used, rather than making the style be a public static data member of the class, is so that a theme can modify a large number of types of widgets without having them all linked into a program. If find() returns null it should just skip that setting code because that widget is not used by this program.

The "revert" function is mostly provided to make it easy to initialize the fields even though C++ does not allow a structure constant. It is also used to undo theme changes when FLTK::reset_theme() is called.

Functions ^

destroy

$namedstyle->destroy( );

Destroy the NamedStyle.

first

my $style = FLTK::first( );

name

my $name = $namedstyle->name( );

new

my $style = $namedstyle->new( $name, $revert, $backptr );
my $style = $namedstyle->new( $existing_style );

next

my $next = $namedstyle->next( );

Author ^

Sanko Robinson <sanko@cpan.org> - http://sankorobinson.com/

License and Legal ^

Copyright (C) 2008-2010 by Sanko Robinson <sanko@cpan.org>

This program is free software; you can redistribute it and/or modify it under the terms of The Artistic License 2.0. See the LICENSE file included with this distribution or notes on the Artistic License 2.0 for clarification.

When separated from the distribution, all original POD documentation is covered by the Creative Commons Attribution-Share Alike 3.0 License. See the clarification of the CCA-SA3.0.

syntax highlighting: