Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > 3d0d0177db421ffde0b64948d214366a > files > 107

polyxmass-doc-0.9.0-1mdv2007.0.noarch.rpm

\chapter[\pxm' Resources]{\pxm' Resources}\label{chap:polyxmass-resources}

The previous chapter dealt with how to configure the \pxm' file-system in such a way that the program can operate smoothly by knowing at each instant where to find critical polymer chemistry configuration data. This chapter is about customizing the \pxm' behaviour to suit the user's needs and tastes, not polymer chemistry. The customizations that the user may perform can be stored into a resource file which is located in the user's \filename{.gnome/\pxmr} resource file. There are a number of personalization options that are saved in this resource file. The settings in this file are performed using a graphical interface module to be described later.

In this chapter we will go through all the \pxm' aspects that the user may configure (and make permanent by saving the configuration to the resource file). To display the window where configuration goes on, pull down the following menu item:\\
\centerline{\guimenu{Resources}\guimenuitem{Resources}}

The window that is displayed presents a number of notebook pages. In these pages the user configures sets of related preferences. The action takes place either by clicking onto a normal button or by choosing an item from a popup menu that is displayed when the user clicks an option menu button. Once such a button has been clicked, the only way to cancel the operation is to choose the ``cancel'' item in it. Unclicking the mouse away from the button is not enough.

The general behaviour of the option menu buttons found in the different pages of the notebook widget in the window which is displayed upon choosing this menu is the following:
\begin{itemize}
\item The \guilabel{apply} option menu button item makes the current settings the valid settings for the program. These current settings are used during the present session but are lost upon program shutdown;
\item The \guilabel{write} option menu button item causes the settings currently displayed on the notebook page to be saved to the \filename{.gnome/\pxmr} file. These settings are thus read upon program launch.
\item The \guilabel{clean section} option menu button item (occurring not in all the cases) causes the settings pertaining to the relevant data to be erased from the resource file. For example, if a list of previously opened files is too long or contains too many items which do no longer exist on disk, the user may want to clean the section (which is to clear the list).
\item The \guilabel{cancel} option menu button item allows the user to renounce to any action while he has already clicked onto the option menu button. It is imperative that this button be selected if the user wants to cancel the operation. If the user leaves the button without releasing the mouse click, then the button item that was initially activated is automatically selected. Be careful with this feature!
\end{itemize}


\section*{The \mbox{\filename{polyxmass}} Resource File}


This file, which we have seen already in previous chapters, is the resource file in which user-specific \pxm\ customization data are stored. In this section we will give a description of each setting that this file is able to understand.

As a reminder, we state here that the user's resource \filename{polyxmass} file is checked for its existence each time the \pxm\ program is run. This is because, upon start, the program will try to use the settings in this file to customize its behaviour. If the file is not found, the program will initialize itself with default reasonable values. See one example of such resource file in the appendix at page~\pageref{apdx:user_resource_file}.

Also we remind that each time ``stock confdata directory'' is used, it designates the directory in which all the \pxm' related data are stored in the installation directory. For example, if the program was installed in the \filename{/usr} standard tree, the stock confdata directory would be \filename{/usr/share/polyxmass}. This stock confdata directory has a \filename{config} subdirectory in which polymer-related data are stored. It is this directory that the user may duplicate in order to reliably modify the polymer-related configuration data. 

In the following sections, we will describe each option that can be set in this file.


\begin{figure}
  \begin{center}
    \includegraphics[scale=2]{figures/raster/resources-dirs-and-files-page.jpg}
  \end{center}
  \caption[Directories and files]{\textbf{Directories and files.} This options' settings window notebook page allows the user to 1) set a number of directories where data are stored for the program to search and 2) to manage the histories about the files that were recently opened in the program.}
  \label{fig:resources-dirs-and-files-page}
\end{figure}


\subsection*{UserWorkDir}


\begin{itemize}
\item Absolute file name of the working directory;
\item Defaults to the user's home directory;
\item See Figure~\ref{fig:resources-dirs-and-files-page}
\item The \pxm' error log file is in this directory (hidden file \filename{.\pxmr-error.log})
\end{itemize}



\subsection*{UserDataDir}


\begin{itemize}
\item Absolute file name of the directory in which the data are stored;
\item Defaults to the \filename{sequences} directory in the stock confdata directory;
\item See Figure~\ref{fig:resources-dirs-and-files-page}
\item Heavily used by the program, specifically when reading/writing polymer sequence files.
\end{itemize}



\subsection*{UserConfigDir}


\begin{itemize}
\item Absolute file name of the directory in which all the polymer definition data are stored;
\item Defaults to the \filename{config} directory in the stock confdata directory;
\item See Figure~\ref{fig:resources-dirs-and-files-page}
\item Heavily used by the program, each time polymer-specific data are required.
\end{itemize}



\subsection*{UserGladeDir}


\begin{itemize}
\item Absolute file name of the directory in which the graphic interface definition files are stored;
\item Defaults to the \filename{glade-interface} directory in the stock confdata directory;
\item See Figure~\ref{fig:resources-dirs-and-files-page}
\item Heavily used by the program, each time a graphical interface is to be built.
\end{itemize}



\subsection*{Recent files history}

\begin{itemize}
\item \guilabel{Clean recent polymer sequences section} will clear the history of the polymer sequence files opened.
\item \guilabel{Clean recent polymer definitions section} will clear the history of the polymer definition files opened.
\item The histories are the log of the files that were either opened or saved as. The items of each history above are visible when the user selects the \guilabel{Recent files} submenu in the main \guilabel{File} menu items for the polymer sequence or the polymer definition files.
\end{itemize}



\subsection*{atom\_decimals}


\begin{figure}
  \begin{center}
    \includegraphics[scale=2]{figures/raster/resources-num-formats-page.jpg}
  \end{center}
  \caption[Numerical formatting strings]{\textbf{Numerical formatting strings.} This options' settings window notebook page allows the user to set the way numerical values are to be displayed throughout all the \pxm' number generating activities. See text for details.}
  \label{fig:resources-num-formats-page}
\end{figure}


\begin{itemize}
\item Tells how the numerical data pertaining to the atoms are to be displayed throughout the program's operation; Please, read the libc documentation for a detailed understanding of the numerical formatting principles;
\item This is set by default to \%.10f (10 decimals);
\item See Figure~\ref{fig:resources-num-formats-page};
\item Heavily used by the program, each time an atom's numerical value is to be displayed.
\end{itemize}



\subsection*{monomer\_decimals}


\begin{itemize}
\item Tells how the numerical data pertaining to the monomers are to be displayed throughout the program's operation; Please, read the libc documentation for a detailed understanding of the numerical formatting principles;
\item This is set by default to \%.5f (5 decimals);
\item See Figure~\ref{fig:resources-num-formats-page};
\item Heavily used by the program, each time a monomer's numerical value is to be displayed.
\end{itemize}




\subsection*{oligomer\_decimals}


\begin{itemize}
\item Tells how the numerical data pertaining to oligomers are to be displayed throughout the program's operation; Please, read the libc documentation for a detailed understanding of the numerical formatting principles;
\item This is set by default to \%.4f (4 decimals);
\item See Figure~\ref{fig:resources-num-formats-page};
\item Heavily used by the program, each time an oligomer's numerical value is to be displayed.
\end{itemize}



\subsection*{fragomer\_decimals}


\begin{itemize}
\item Tells how the numerical data pertaining to fragomers are to be displayed throughout the program's operation; Please, read the libc documentation for a detailed understanding of the numerical formatting principles;
\item This is set by default to \%.4f (4 decimals);
\item See Figure~\ref{fig:resources-num-formats-page};
\item Heavily used by the program, each time a fragomer's numerical value is to be displayed.
\end{itemize}



\subsection*{polymer\_decimals}


\begin{itemize}
\item Tells how the numerical data pertaining to polymers are to be displayed throughout the program's operation; Please, read the libc documentation for a detailed understanding of the numerical formatting principles;
\item This is set by default to \%.3f (3 decimals);
\item See Figure~\ref{fig:resources-num-formats-page};
\item Heavily used by the program, each time a polymer's numerical value is to be displayed.
\end{itemize}



\subsection*{maxMonomCodeLen}


\begin{figure}
  \begin{center}
    \includegraphics[scale=2]{figures/raster/resources-varia-page.jpg}
  \end{center}
  \caption[Varia data]{\textbf{Varia data.} This options' settings window notebook page allows the user to set a number of configuration settings. As of time of writing this notebook page allows the user to configure 1) the maximum number of characters allowed for coding a monomer (set to 3 in our example), 2) the geometries of some selected important windows and 3) the way the molecular calculator should be displayed in its window. (See text for details.)}
  \label{fig:resources-varia-page}
\end{figure}

\begin{itemize}
\item Maximum number of characters any monomer code may be made of. A value of \cfgval{3} would tell \pxm\ that any monomer code cannot be longer than 3 characters (``Aaa'' is OK, for example, but ``Aaab'' is bad);
\item This is set by default to 3;
\item See Figure~\ref{fig:resources-varia-page}
\item Heavily used by the program each time a monomer code is used.
\end{itemize}



\subsection*{Geometries of the window widgets}


\begin{itemize}
\item The user may select the windows for which he wants that the program ceases to remember what were their size and position. In fact, each time the user closes a window,\footnote{Only relevant windows do display this functionality} this window stores its dimensions and position in the resource file so that the next time it is opened, it is displayed at the very same place with the same size. This allows the user to set a screen layout that corresponds to his ergonomic requirements or merely to his best visual positioning of window widgets and to store it to disk.
\end{itemize}


\subsection*{Display of the molecular calculator}


\begin{itemize}
\item The user may select the widget elements that the molecular calculator should use to display its contents. 
\end{itemize}


\subsection*{Fonts and colors}


\begin{figure}
  \begin{center}
    \includegraphics[scale=2]{figures/raster/resources-fonts-and-colors-page.jpg}
  \end{center}
  \caption[Fonts and colors data]{\textbf{Fonts and colors data.} This options' settings window notebook page allows the user to set a number of fonts for a number of text displaying widgets.}
  \label{fig:resources-fonts-and-colors-page}
\end{figure}

\begin{itemize}
\item  The user may choose the font used to display text in some widgets in which large amounts of text are displayed. These widgets for the moment are the program's console window, the about box (in which big portions of text are displayed) and the generic text displaying windows that are used throughout the program. A triple-click into the text entries will elicit the pop of a font selection window. The picture explains this clearly.
\item  The user may choose the color to use when underlining monomer icons with a line upon Find/Replace operations.
\end{itemize}













\cleardoublepage