<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">\hypertarget{namespaceUtil}{\section{Util Namespace Reference}
\label{namespaceUtil}\index{Util@{Util}}
}


Various utility functions.  


\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{Util_8h_aa46c51f55fbb56c9ca52a7ac84ac4231}{string\-\_\-list} \&amp; \hyperlink{namespaceUtil_a70b2b64bbb3e376323a1214c66093dff}{tokenise\-\_\-string} (string str)
\begin{DoxyCompactList}\small\item\em Tokenise string at whitespace. \end{DoxyCompactList}\item 
char $\ast$$\ast$ \hyperlink{namespaceUtil_accf7e824cbe694afa466690e9cf9183a}{string\-\_\-list\-\_\-to\-\_\-array} (\hyperlink{Util_8h_aa46c51f55fbb56c9ca52a7ac84ac4231}{string\-\_\-list} \&amp;l)
\begin{DoxyCompactList}\small\item\em Convert a {\ttfamily string\-\_\-list} to a null-\/terminated array of character pointers. \end{DoxyCompactList}\item 
void \hyperlink{namespaceUtil_aa085777cc7de806ff22abebafd2bdced}{delete\-\_\-string\-\_\-array} (char $\ast$$\ast$sl)
\begin{DoxyCompactList}\small\item\em Deletes the array of strings returned by \hyperlink{namespaceUtil_accf7e824cbe694afa466690e9cf9183a}{string\-\_\-list\-\_\-to\-\_\-array}. \end{DoxyCompactList}\item 
bool \hyperlink{namespaceUtil_a604868a21366d1806251dceaef37258f}{parse\-R\-G\-B} (\hyperlink{classBitmap_ab6604549161b479f99751d12182979f7}{Bitmap\-::\-Bitmap\-Colour} \&amp;, const char $\ast$)
\begin{DoxyCompactList}\small\item\em Parse an R\-G\-B specification. \end{DoxyCompactList}\item 
void \hyperlink{namespaceUtil_a6d7f08b200ad0f09c189dd9cb2fc2220}{verbosity} (const \hyperlink{verbosity_8h_a886df075e73fd6d54e018791f87fa071}{verbosities} level)
\begin{DoxyCompactList}\small\item\em Sets the verbosity of the methods in this class. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Variables}
\begin{DoxyCompactItemize}
\item 
\hyperlink{verbosity_8h_a886df075e73fd6d54e018791f87fa071}{verbosities} \hyperlink{namespaceUtil_a76bbcd9037ee2470e06894e3b5d23fd8}{verbosity\-\_\-} = \hyperlink{verbosity_8h_a886df075e73fd6d54e018791f87fa071aebc81705969b8c5ae986b0b2ec08d1d5}{normal}
\end{DoxyCompactItemize}


\subsection{Detailed Description}
Various utility functions. 

\subsection{Function Documentation}
\hypertarget{namespaceUtil_aa085777cc7de806ff22abebafd2bdced}{\index{Util@{Util}!delete\-\_\-string\-\_\-array@{delete\-\_\-string\-\_\-array}}
\index{delete\-\_\-string\-\_\-array@{delete\-\_\-string\-\_\-array}!Util@{Util}}
\subsubsection[{delete\-\_\-string\-\_\-array}]{\setlength{\rightskip}{0pt plus 5cm}void Util\-::delete\-\_\-string\-\_\-array (
\begin{DoxyParamCaption}
\item[{char $\ast$$\ast$}]{sl}
\end{DoxyParamCaption}
)}}\label{namespaceUtil_aa085777cc7de806ff22abebafd2bdced}


Deletes the array of strings returned by \hyperlink{namespaceUtil_accf7e824cbe694afa466690e9cf9183a}{string\-\_\-list\-\_\-to\-\_\-array}. 


\begin{DoxyParams}{Parameters}
{\em sl} &amp; a null-\/terminated array of strings \\
\hline
\end{DoxyParams}
\hypertarget{namespaceUtil_a604868a21366d1806251dceaef37258f}{\index{Util@{Util}!parse\-R\-G\-B@{parse\-R\-G\-B}}
\index{parse\-R\-G\-B@{parse\-R\-G\-B}!Util@{Util}}
\subsubsection[{parse\-R\-G\-B}]{\setlength{\rightskip}{0pt plus 5cm}bool Util\-::parse\-R\-G\-B (
\begin{DoxyParamCaption}
\item[{{\bf Bitmap\-::\-Bitmap\-Colour} \&amp;}]{rgb, }
\item[{const char $\ast$}]{s}
\end{DoxyParamCaption}
)}}\label{namespaceUtil_a604868a21366d1806251dceaef37258f}


Parse an R\-G\-B specification. 

This is either a sequence of three integers separated by slashes (or in fact any non-\/number character), or else a string of the form {\ttfamily \#R\-R\-G\-G\-B\-B}. Set the `rgb' structure to the resulting numbers. The integers must be in the range \mbox{[}0,255\mbox{]}, and may be specified in decimal, octal, or hex.


\begin{DoxyParams}{Parameters}
{\em rgb} &amp; the {\ttfamily Bitmap\-Colour} corresponding to the {\ttfamily s} argument \\
\hline
{\em s} &amp; the R\-G\-B specification\\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
true if the parse is successful. 
\end{DoxyReturn}


References Bitmap\-::\-Bitmap\-Colour\-\_\-s\-::blue, Bitmap\-::\-Bitmap\-Colour\-\_\-s\-::green, and Bitmap\-::\-Bitmap\-Colour\-\_\-s\-::red.



Referenced by main().

\hypertarget{namespaceUtil_accf7e824cbe694afa466690e9cf9183a}{\index{Util@{Util}!string\-\_\-list\-\_\-to\-\_\-array@{string\-\_\-list\-\_\-to\-\_\-array}}
\index{string\-\_\-list\-\_\-to\-\_\-array@{string\-\_\-list\-\_\-to\-\_\-array}!Util@{Util}}
\subsubsection[{string\-\_\-list\-\_\-to\-\_\-array}]{\setlength{\rightskip}{0pt plus 5cm}char $\ast$$\ast$ Util\-::string\-\_\-list\-\_\-to\-\_\-array (
\begin{DoxyParamCaption}
\item[{{\bf string\-\_\-list} \&amp;}]{l}
\end{DoxyParamCaption}
)}}\label{namespaceUtil_accf7e824cbe694afa466690e9cf9183a}


Convert a {\ttfamily string\-\_\-list} to a null-\/terminated array of character pointers. 

The resulting array can conveniently be deleted using \hyperlink{namespaceUtil_aa085777cc7de806ff22abebafd2bdced}{delete\-\_\-string\-\_\-array}.


\begin{DoxyParams}{Parameters}
{\em l} &amp; a string\-\_\-list \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
a pointer to a null-\/terminated array of null-\/terminated character arrays 
\end{DoxyReturn}


Referenced by Pipe\-Stream\-::\-Pipe\-Stream().

\hypertarget{namespaceUtil_a70b2b64bbb3e376323a1214c66093dff}{\index{Util@{Util}!tokenise\-\_\-string@{tokenise\-\_\-string}}
\index{tokenise\-\_\-string@{tokenise\-\_\-string}!Util@{Util}}
\subsubsection[{tokenise\-\_\-string}]{\setlength{\rightskip}{0pt plus 5cm}{\bf string\-\_\-list} \&amp; Util\-::tokenise\-\_\-string (
\begin{DoxyParamCaption}
\item[{string}]{str}
\end{DoxyParamCaption}
)}}\label{namespaceUtil_a70b2b64bbb3e376323a1214c66093dff}


Tokenise string at whitespace. 


\begin{DoxyParams}{Parameters}
{\em str} &amp; the string to be tokenised \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
a list containing the whitespace-\/separated tokens in the string 
\end{DoxyReturn}


References normal, and verbosity\-\_\-.



Referenced by main(), and Pipe\-Stream\-::\-Pipe\-Stream().

\hypertarget{namespaceUtil_a6d7f08b200ad0f09c189dd9cb2fc2220}{\index{Util@{Util}!verbosity@{verbosity}}
\index{verbosity@{verbosity}!Util@{Util}}
\subsubsection[{verbosity}]{\setlength{\rightskip}{0pt plus 5cm}void Util\-::verbosity (
\begin{DoxyParamCaption}
\item[{const {\bf verbosities}}]{level}
\end{DoxyParamCaption}
)}}\label{namespaceUtil_a6d7f08b200ad0f09c189dd9cb2fc2220}


Sets the verbosity of the methods in this class. 


\begin{DoxyParams}{Parameters}
{\em level} &amp; how verbose the class's methods should be \\
\hline
\end{DoxyParams}


References verbosity\-\_\-.



Referenced by main().



\subsection{Variable Documentation}
\hypertarget{namespaceUtil_a76bbcd9037ee2470e06894e3b5d23fd8}{\index{Util@{Util}!verbosity\-\_\-@{verbosity\-\_\-}}
\index{verbosity\-\_\-@{verbosity\-\_\-}!Util@{Util}}
\subsubsection[{verbosity\-\_\-}]{\setlength{\rightskip}{0pt plus 5cm}{\bf verbosities} Util\-::verbosity\-\_\- = {\bf normal}}}\label{namespaceUtil_a76bbcd9037ee2470e06894e3b5d23fd8}


Referenced by Input\-Byte\-Stream\-::bind\-To\-File\-Descriptor(), Bitmap\-::\-Bitmap(), Input\-Byte\-Stream\-::buffer\-Seek(), Input\-Byte\-Stream\-::close(), Pk\-Font\-::fontgen\-Command(), Pk\-Font\-::magnification(), Input\-Byte\-Stream\-::open\-Source\-Spec(), Bitmap\-::paint(), Input\-Byte\-Stream\-::reload\-Buffer(), Bitmap\-::rule(), Bitmap\-::scale\-Down(), Bitmap\-::strut(), Pk\-Font\-::substitute\-\_\-font\-\_\-string(), tokenise\-\_\-string(), verbosity(), and Bitmap\-::write().

</pre></body></html>