App-Chart
view release on metacpan or search on metacpan
lib/App/Chart/Gtk2/GUI.pm view on Meta::CPAN
($widget, { foreground => $color_obj,
line_style => 'solid',
line_width => 0 })
});
}
sub gc_for_colour_dashed {
my ($widget, $colour_str) = @_;
($colour_str, my $color_obj) = color_object ($widget, $colour_str);
return ($widget->{'gc_dash'}->{$colour_str} ||= do {
require App::Chart::Gtk2::Ex::GtkGCBits;
App::Chart::Gtk2::Ex::GtkGCBits->get_for_widget
($widget, { foreground => $color_obj,
line_style => 'on_off_dash',
line_width => 0 })
});
}
1;
__END__
# =for stopwords Pango undef Gtk ListStore TreeStore renderer TreeViewColumn TreeView
#
# =head1 NAME
#
# App::Chart::Gtk2::GUI -- miscellaneous graphical interface functions
#
# =head1 SYNOPSIS
#
# use App::Chart::Gtk2::GUI;
#
# =head1 FUNCTIONS
#
# =over 4
#
# =cut
#
# =item App::Chart::Gtk2::GUI::string_width ($widget_or_layout, $str)
#
# Return the width in pixels of C<$str> in the font of the given widget or
# layout (either a C<Gtk2::Widget> or a C<Gtk2::Pango::Layout> object).
#
# =cut
#
# =item C<< App::Chart::Gtk2::GUI::draw_text_centred ($widget, $region_or_event, $string) >>
#
# Draw C<string> centred in the window of C<widget>. If C<widget> isn't
# realized yet then do nothing. Pango C<word-char> wrapping is enabled, so
# the string is not truncated if it's wider than the window.
#
# Both windowed and no-window widgets can be given here. C<$region_or_event>
# gives a region to clip to, or undef to draw everything.
#
# =cut
#
# =item App::Chart::Gtk2::GUI::chart_style_class ($class)
#
# =item App::Chart::Gtk2::GUI::chart_style_widget ($widgetname)
#
# Setup package C<$class> or widget C<$widgetname> (per
# C<< $widget->set_name >>) to get the Chart graph style settings, which means
# black background and white foreground and text.
#
# C<$class> can include colons like C<"App::Chart::Gtk2::HAxis"> and they're turned
# into underscores like C<"App__Chart__Gtk2__HAxis"> which is the Gtk class
# name.
#
# =cut
#
# =back
( run in 1.078 second using v1.01-cache-2.11-cpan-f56aa216473 )