.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "HDF5::tkview 3pm" .TH HDF5::tkview 3pm 2024-01-10 "perl v5.38.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME PDL::IO::HDF5::tkview \- View HDF5 files using perl/tk and PDL::IO::HDF5 modules .SH DESCRIPTION .IX Header "DESCRIPTION" This is a experimental object to view HDF5 files the PDL::IO::HDF5 module. The HDF files are displayed in a tree structure using Tk::Tree .SH SYNOPSIS .IX Header "SYNOPSIS" .Vb 3 \& use Tk; \& use PDL::IO::HDF5::tkview \& use PDL::IO::HDF5; \& \& my $mw = MainWindow\->new; \& \& \& my $h5 = new PDL::IO::HDF5(\*(Aqdatafile.h5\*(Aq); # open HDF5 file object \& \& my $tkview = new PDL::IO::HDF5::tkview( $mw, $h5); \& \& MainLoop; .Ve .SH "MEMBER DATA" .IX Header "MEMBER DATA" .IP mw 1 .IX Item "mw" Tk window where the file structure is displayed. .IP H5obj 1 .IX Item "H5obj" PDL::IO::HDF5 Object .IP hl 1 .IX Item "hl" Tk Hlist object .IP dataDisplaySub 1 .IX Item "dataDisplaySub" Sub ref to execute when a dataset is double-clicked. This defaults to a print of the dataset. See dataDisplaySubSet for details. .Sp Tk Hlist object .SH METHODS .IX Header "METHODS" ####\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- .SS new .IX Subsection "new" PDL::IO::HDF5::tkview Constructor \- creates new object .PP \&\fBUsage:\fR .PP .Vb 1 \& $tkview = new PDL::IO::HDF5::tkview( $mw, $H5obj); \& \& Where: \& $mw Tk window \& $H5obj PDL::IO::HDF5::Object .Ve .SS dataDisplaySubSet .IX Subsection "dataDisplaySubSet" Set the dataDisplaySub data member. .PP \&\fBUsage:\fR .PP .Vb 3 \& # Data Display sub to call when a dataset is double\-clicked \& my $dataDisplay = sub{ my $data = $_[0]; print "I\*(Aqm Displaying This $data\en";}; \& $tkview\->dataDisplaySubSet($dataDisplay); .Ve .PP The dataDisplaySub data member is a perl sub ref that is called when a dataset is double-clicked. This data member is initially set to just print the dataset's data to the command line. Using the dataDisplaySubSet method, different actions for displaying the data can be "plugged-in". .SS activateCmd .IX Subsection "activateCmd" Internal Display method invoked whenever a tree element is activated (i.e. double-clicked). This method does nothing unless a dataset element has been selected. It that cases it calls \f(CW$self\fR\->dataDisplaySub with the data.