Giter Site home page Giter Site logo

simplegtk2's Introduction

SimpleGtk2 version 0.68
=======================

SimpleGtk2 is a wrapper around Perl-Gtk2 to allow RAD (Rapid Application 
Development). It is based on GtkFixed container which allows creating 
applications with a minimal effort.

The most needed widgets are implemented with its common functions.

But it is also possible to use the original functions provided by 
Perl-Gtk2.


The following widgets are implemented:

Windows
    - GtkWindow (toplevel)
    - GtkDialog (planned)
    - GtkMessageDialog (normal, simple and standalone simple)
    - GtkAboutDialog (planned)
    - GtkAssistant (planned)

Display Widgets
    - GtkImage
    - GtkLabel
    - GtkProgressBar (planned)
    - GtkStatusbar
    - GtkStatusIcon (perhaps)
    
Buttons and Toggles
    - GtkButton
    - GtkCheckButton
    - GtkRadioButton
    - GtkLinkButton
    - GtkFontButton
    - GtkFilechooserButton
    
Numeric/Text Data Entry
    - GtkEntry
    - GtkSlider (GtkHScale & GtkVScale)
    - GtkSpinButton 

Multiline Text Editor
    - GtkTextView

Tree, List and Icon Grid Widgets
    - GtkTreeView (in progress)
    - GtkListView (in progress)
    
Menus, Combo Box, Toolbar
    - GtkComboBox
    - GtkMenu
    - GtkMenuBar
    - GtkMenuItem
        - GtkImageMenuItem
        - GtkRadioMenuItem
        - GtkCheckMenuItem
        - GtkSeparatorMenuItem 
        - GtkTearoffMenuItem
    - GtkToolbar (planned)

Selectors (File/Font/Color)
    - GtkColorSelectionDialog (planned)
    - GtkFileChooserDialog (normal and simple)
    - GtkFontSelectionDialog (normal and simple)

Layout Containers
    - GtkNotebook
    - GtkNotebookPage

Ornaments
    - GtkFrame
    - GtkSeparator (GtkHSeparator & GtkVSeparator)

Scrolling
    - GtkScrollbar (GtkHScrollbar & GtkVScrollbar)

Printing
    - GtkPrintUnixDialog (perhaps)
    - GtkPageSetupUnixDialog (perhaps)

Miscellaneous
    - GtkTooltip


EXAMPLE

The 'Hello World' example ;-)

Original with Perl-Gtk2:

    #! /usr/bin/perl -w
    use strict;
    use Gtk2 -init;

    # toplevel window
    my $window = Gtk2::Window->new('toplevel');
    $window->signal_connect(delete_event => sub { Gtk2->main_quit });

    # button
    my $button = Gtk2::Button->new('Action');
    $button->signal_connect(clicked => sub{print("Hello Gtk2-Perl\n");});

    # add button and show window
    $window->add($button);
    $window->show_all();

    Gtk2->main;

With SimpleGtk2:

    #! /usr/bin/perl -w
    use strict;
    use SimpleGtk2;

    # toplevel window
    my $window = SimpleGtk2->new_window(Type => 'toplevel', 
                                        Name => 'main', 
                                        Title => 'Hello World');
    $window->add_signal_handler('main', 'delete_event', 
                                        sub { Gtk2->main_quit; });

    # button
    $window->add_button(Name => 'button', Pos => [20, 40], 
                        Title => "Action", Sig => 'clicked', 
                        Func => sub {print("Hello Gtk2-Perl\n");});
    # show window
    $window->show_and_run();


INSTALLATION

To install this module type the following:

   perl Makefile.PL
   make
   make test
   make install


DEPENDENCIES

This module requires these other modules and libraries:

  Test
  Perl-Gtk2


COPYRIGHT AND LICENCE

Copyright (C) 2015 by Thomas Funk
for SimpleGtk2

Copyright (C) 2004 by the Gtk2-Perl team 
for Gtk2::Ex::Simple::List and Gtk2::Ex::Simple::Tree

These libraries are free software; you can redistribute them and/or 
modify them under the same terms as GPL V2 or higher.


BUGS

Please send me bug reports or suggestions for improvements to
<[email protected]> excepting Gtk2::Ex::Simple::List and 
Gtk2::Ex::Simple::Tree.

simplegtk2's People

Contributors

thomasfunk avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.