CLASS HIERARCHY

DESCRIPTION

This is a POD documentation browser frame. The POD is displayed using Wx::Perl::PodRichText (which is a RichTextCtrl). There's menus for various features and the links in the text can be followed to other documents.

Programming

The initial window size follows the 80x30 initial size of the Wx::Perl::PodRichText display widget. Program code or the user can make the window bigger or smaller as desired.

The menubar is available from the usual Wx::Frame method $browser->GetMenuBar() to make additions or modifications. The quit menu item (Wx::wxID_EXIT) closes the window with $browser->quit() described below. In a multi-window program this only closes the PodBrowser window, it doesn't exit the whole program.

See wx-perl-podbrowser for a standalone program running a PodBrowser window. Or see examples/podbrowser.pl in the Wx-Perl-PodBrowser sources for a minimal program.

FUNCTIONS

Creation

$browser = Wx::Perl::PodBrowser->new ()

$browser = Wx::Perl::PodBrowser->new ($parent, $id, $title)

Create and return a new browser window widget.

The optional $parent, $id and $title arguments are per Wx::Frame->new().

The default $title is "POD Browser". An application could set something more specific if displaying its own help pages, either when creating the browser or later with the usual Wx::TopLevelWindow method $browser->SetTitle($title).

Methods

$browser->go_back()

$browser->go_forward()

Go back or forward to the next or previous POD module or file. These are the "File/Back" and "File/Forward" menu entries.

$browser->goto_own_pod()

Go to the POD of the PodBrowser module itself. This is the "Help/POD Browser POD" menu entry.

$browser->reload()

Re-read the current POD module or file. This is the "File/Reload" menu entry.

$browser->quit()

Close the PodBrowser window. This is the "File/Quit" menu entry (which is wxID_EXIT). It closes the window with the usual Wx::Frame method $browser->Close().

The EVT_CLOSE() handler does a $browser->Destroy() to destroy the browser. Perhaps there should be an option to only Hide(), so an application could keep a single browser window. Is there a conventional way to choose that?

Printing

$browser->popup_print()

Open a print dialog for the POD document. This is the "File/Print" menu entry (which is wxID_PRINT).

$browser->popup_print_preview()

Open a print-preview dialog for the POD document. This is the "File/Print Preview" menu entry (which is wxID_PREVIEW).

$browser->popup_print_setup()

Open a printer page setup dialog. This is the "File/Page Setup" menu entry (which is wxID_PRINT_SETUP).

About Dialog

$browser->popup_about_dialog()

Open the "about" dialog for $browser. This is the Help/About menu entry (the usual wxID_ABOUT). It displays a Wx::AboutBox() containing the $browser->about_dialog_info() below.

HOME PAGE

LICENSE

Copyright 2012, 2013 Kevin Ryde

Wx-Perl-PodBrowser is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.

Wx-Perl-PodBrowser is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.