Chandra-EPUB

 view release on metacpan or  search on metacpan

lib/Chandra/EPUB.pm  view on Meta::CPAN


	Chandra::EPUB->open('mybook.epub');

...

	my $book = Chandra::EPUB->new(
		file => 'mybook.epub'
		width => 800, # optional
		height => 600, # optional
		title => 'My Book', # optional	
	);
	$book->run();

=head1 DESCRIPTION

Chandra::EPUB is an EPUB reader built with Perl and Chandra. It allows you to open and read Epub files, navigate through chapters, and customize the reading experience with optional settings such as width, height, and title.

=cut

=head1 METHODS

=head2 open

Open an EPUB file and start the reader. Same as calling new with the file and then run.

	Chandra::EPUB->open('mybook.epub');

=cut

=head2 new

Instantiate a new Chandra::EPUB object. You can provide the file path to the EPUB book, as well as optional settings for width, height, and title.

	my $book = Chandra::EPUB->new(
		file => 'mybook.epub'
		width => 800, # optional
		height => 600, # optional
		title => 'My Book', # optional	
	);

=cut

=head2 run

Run the EPUB reader application. This will open a window and display the contents of the EPUB book.

	$book->run();

=cut

=head2 load_epub

Load the EPUB file and extract its contents, including CSS, chapters, and images.

	my $book_data = load_epub('mybook.epub');

=cut

=head2 extract_body

Extract the inner content of the <body> tag from the given XHTML string.

	my $body = extract_body($xhtml);

=cut

=head1 AUTHOR

lnation <email@lnation.org>

=head1 BUGS

Please report any bugs or feature requests to C<bug-chandra-epub at rt.cpan.org>, or through
the web interface at L<https://rt.cpan.org/NoAuth/ReportBug.html?Queue=Chandra-EPUB>.  I will be notified, and then you'll
automatically be notified of progress on your bug as I make changes.

=head1 SUPPORT

You can find documentation for this module with the perldoc command.

	perldoc Chandra::EPUB

You can also look for information at:

=over 4

=item * RT: CPAN's request tracker (report bugs here)

L<https://rt.cpan.org/NoAuth/Bugs.html?Dist=Chandra-EPUB>

=item * Search CPAN

L<https://metacpan.org/release/Chandra-EPUB>

=back

=head1 ACKNOWLEDGEMENTS

=head1 LICENSE AND COPYRIGHT

This software is Copyright (c) 2026 by lnation <email@lnation.org>.

This is free software, licensed under:

	The Artistic License 2.0 (GPL Compatible)


=cut

1; # End of Chandra::EPUB



( run in 1.022 second using v1.01-cache-2.11-cpan-5837b0d9d2c )