<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<section xmlns="http://docbook.org/ns/docbook" version="5.0" xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="_bshow__file_8tcl">
<title>/Users/bernard/b20/bsoft/tcltk/bshow_file.tcl File Reference</title>
<indexterm><primary>/Users/bernard/b20/bsoft/tcltk/bshow_file.tcl</primary></indexterm>
<para>

<para>Procedures to manage file I/O. </para>
 
</para>
<simplesect>
    <title>Functions    </title>
        <itemizedlist>
            <listitem><para><link linkend="_bshow__file_8tcl_1ac737a661a0cad8d808f3036ce2b34192">setupFileMenu</link></para>

<para>Menu for opening and closing image files and quiting. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a3291308c7a4b5ec32fcc2af7168824a3">fileDialog</link> operation</para>

<para>Selects a file for reading or writing using a standard dialog. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a8c01f58de6a5a6344a96da899dd861eb">openNode</link> tree node</para>

<para>Populates a file browser tree node. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a239a3b24e871d1e198f70449d5b6f179">setupFileBrowser</link> w</para>

<para>Points the file browser to the current directory. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1affa385e5392d3879abcfa2a7d72b9502">openFileFromTree</link> wtree</para>

<para>Opens a file indicated by a double-click in the file browser. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a4d2b6ed9a2375263a6352bac31245c4b">fileBrowserWindow</link> w</para>

<para>Sets up the file browser window. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1aa03342e136ecabf76af72e1ade168b2d">loadImage</link> filename img_num</para>

<para>Loads the selected file into a photo image for display. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a49d8ddf2bfb446c561850c9580537049">relativePath</link> cdir path</para>

<para>Derives the relative path from an absolute one relative to a given directory. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1ad1cd50f440e4932eff6fe1f74e244499">getInfo</link> filename</para>

<para>Loads the information for the current image file into a text window for display. </para>
</listitem>
            <listitem><para><link linkend="_bshow__file_8tcl_1a1c94c61bf3793b19b9a5888b1db46c2f">writePostScript</link></para>

<para>Writes the current canvas to a postscript file. </para>
</listitem>
        </itemizedlist>
</simplesect>
<section>
<title>Detailed Description</title>

<para>Procedures to manage file I/O. </para>

<para><formalpara><title>Author: </title>

<para>Bernard Heymann </para>
</formalpara>
<formalpara><title>Date: </title>

<para>Created: 20010516 </para>

<para>Modified: 20191112 </para>
</formalpara>
</para>
</section>
<section>
<title>Function Documentation</title>
<anchor xml:id="_bshow__file_8tcl_1a4d2b6ed9a2375263a6352bac31245c4b"/>    <section>
    <title>fileBrowserWindow()</title>
<indexterm><primary>fileBrowserWindow</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>fileBrowserWindow</secondary></indexterm>
<para><computeroutput>fileBrowserWindow w </computeroutput></para><para>

<para>Sets up the file browser window. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>w</entry>
                                <entry>
<para>Window name. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 204 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1a3291308c7a4b5ec32fcc2af7168824a3"/>    <section>
    <title>fileDialog()</title>
<indexterm><primary>fileDialog</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>fileDialog</secondary></indexterm>
<para><computeroutput>fileDialog operation </computeroutput></para><para>

<para>Selects a file for reading or writing using a standard dialog. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>operation</entry>
                                <entry>
<para>&quot;open&quot;, &quot;save&quot; or &quot;saveAs&quot;. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 67 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1ad1cd50f440e4932eff6fe1f74e244499"/>    <section>
    <title>getInfo()</title>
<indexterm><primary>getInfo</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>getInfo</secondary></indexterm>
<para><computeroutput>getInfo filename </computeroutput></para><para>

<para>Loads the information for the current image file into a text window for display. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>filename</entry>
                                <entry>
<para>Image file name. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 391 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1aa03342e136ecabf76af72e1ade168b2d"/>    <section>
    <title>loadImage()</title>
<indexterm><primary>loadImage</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>loadImage</secondary></indexterm>
<para><computeroutput>loadImage filename img_num </computeroutput></para><para>

<para>Loads the selected file into a photo image for display. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>filename</entry>
                                <entry>
<para>Image file name. </para>
</entry>
                            </row>
                            <row>
                                <entry>img_num</entry>
                                <entry>
<para>Sub-image number. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 263 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1affa385e5392d3879abcfa2a7d72b9502"/>    <section>
    <title>openFileFromTree()</title>
<indexterm><primary>openFileFromTree</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>openFileFromTree</secondary></indexterm>
<para><computeroutput>openFileFromTree wtree </computeroutput></para><para>

<para>Opens a file indicated by a double-click in the file browser. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>wtree</entry>
                                <entry>
<para>File browser tree. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 176 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1a8c01f58de6a5a6344a96da899dd861eb"/>    <section>
    <title>openNode()</title>
<indexterm><primary>openNode</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>openNode</secondary></indexterm>
<para><computeroutput>openNode tree node </computeroutput></para><para>

<para>Populates a file browser tree node. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>tree</entry>
                                <entry>
<para>File browser tree. </para>
</entry>
                            </row>
                            <row>
                                <entry>node</entry>
                                <entry>
<para>File browser node. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 109 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1a49d8ddf2bfb446c561850c9580537049"/>    <section>
    <title>relativePath()</title>
<indexterm><primary>relativePath</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>relativePath</secondary></indexterm>
<para><computeroutput>relativePath cdir path </computeroutput></para><para>

<para>Derives the relative path from an absolute one relative to a given directory. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>cdir</entry>
                                <entry>
<para>Current directory. </para>
</entry>
                            </row>
                            <row>
                                <entry>path</entry>
                                <entry>
<para>Absolute path to convert. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 361 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1a239a3b24e871d1e198f70449d5b6f179"/>    <section>
    <title>setupFileBrowser()</title>
<indexterm><primary>setupFileBrowser</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>setupFileBrowser</secondary></indexterm>
<para><computeroutput>setupFileBrowser w </computeroutput></para><para>

<para>Points the file browser to the current directory. </para>
</para>

<para>
                <formalpara>
                    <title>
Parameters                    </title>
                    <para>
                    <table frame="all">
                        <tgroup cols="2" align="left" colsep="1" rowsep="1">
                        <colspec colwidth="1*"/>
                        <colspec colwidth="4*"/>
                        <tbody>
                            <row>
                                <entry>w</entry>
                                <entry>
<para>File browser tree. </para>
</entry>
                            </row>
                        </tbody>
                        </tgroup>
                    </table>
                    </para>
                </formalpara>
                </para>
<para>
Definition at line 157 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1ac737a661a0cad8d808f3036ce2b34192"/>    <section>
    <title>setupFileMenu()</title>
<indexterm><primary>setupFileMenu</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>setupFileMenu</secondary></indexterm>
<para><computeroutput>setupFileMenu</computeroutput></para><para>

<para>Menu for opening and closing image files and quiting. </para>
</para>
<para>
Definition at line 16 of file bshow_file.tcl.</para>
    </section><anchor xml:id="_bshow__file_8tcl_1a1c94c61bf3793b19b9a5888b1db46c2f"/>    <section>
    <title>writePostScript()</title>
<indexterm><primary>writePostScript</primary><secondary>bshow_file.tcl</secondary></indexterm>
<indexterm><primary>bshow_file.tcl</primary><secondary>writePostScript</secondary></indexterm>
<para><computeroutput>writePostScript</computeroutput></para><para>

<para>Writes the current canvas to a postscript file. </para>
</para>
<para>
Definition at line 436 of file bshow_file.tcl.</para>
</section>
</section>
</section>
