Cosmetic changes in setup0.h; Latex edits; PaletteSize -> wxPaletteSize;

generate newgrid VC++ project files


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4179 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
1999-10-25 13:46:48 +00:00
parent 6ac64257e4
commit 448af9a46e
27 changed files with 181 additions and 226 deletions

View File

@@ -619,6 +619,17 @@ samples/grid/*.xpm
samples/grid/*.ico samples/grid/*.ico
samples/grid/*.bmp samples/grid/*.bmp
samples/newgrid/*.cpp
samples/newgrid/*.h
samples/newgrid/*.def
samples/newgrid/*.rc
samples/newgrid/*.txt
samples/newgrid/makefile*
samples/newgrid/*.xbm
samples/newgrid/*.xpm
samples/newgrid/*.ico
samples/newgrid/*.bmp
samples/internat/*.cpp samples/internat/*.cpp
samples/internat/*.h samples/internat/*.h
samples/internat/*.def samples/internat/*.def

View File

@@ -1,24 +1,10 @@
wxWindows 2 Change Log wxWindows 2 Change Log
---------------------- ----------------------
2.1.0, b?, June 2nd 1999 NOTE: for changes after wxWindows 2.1.0 b4, please see the CVS
------------------------ change log.
wxGTK: Major improvements are listed in readme.txt.
wxMSW:
wxMotif:
General:
- Fixed day_of_week bug (Peter Stadel).
- Added Inside(), SetLeft/Right/Top/Bottom, +, += to wxRect.
- Added wxHTML, an HTML library and widget.
- Added ZIP input stream.
2.1.0, b4, May 9th 1999 2.1.0, b4, May 9th 1999
----------------------- -----------------------

View File

@@ -190,14 +190,22 @@ Metrowerks CodeWarrior.
\section{Availability and location of wxWindows} \section{Availability and location of wxWindows}
wxWindows is currently available from the Artificial Intelligence wxWindows is available by anonymous FTP and World Wide Web:
Applications Institute by anonymous FTP and World Wide Web:
\begin{verbatim} \begin{verbatim}
ftp://www.remstar.com/pub/wxwin ftp://www.remstar.com/pub/wxwin
http://www.wxwindows.org http://www.wxwindows.org
\end{verbatim} \end{verbatim}
You can also buy a CD-ROM using the form on the Web site, or by contacting:
Julian Smart\\
12 North Street West\\
Uppingham\\
Rutland\\
LE15 9SG\\
julian.smart@ukonline.co.uk
\section{Acknowledgments} \section{Acknowledgments}
Thanks are due to AIAI for being willing to release the original version of Thanks are due to AIAI for being willing to release the original version of
@@ -212,7 +220,7 @@ Dunn, Hermann Dunkel, Jos van Eijndhoven, Tom Felici, Thomas Fettig, Matthew Fla
Wolfram Gloger, Norbert Grotz, Stefan Gunter, Bill Hale, Patrick Halke, Stefan Hammes, Guillaume Helle, Harco de Hilster, Cord Hockemeyer, Markus Wolfram Gloger, Norbert Grotz, Stefan Gunter, Bill Hale, Patrick Halke, Stefan Hammes, Guillaume Helle, Harco de Hilster, Cord Hockemeyer, Markus
Holzem, Olaf Klein, Leif Jensen, Bart Jourquin, Guilhem Lavaux, Jan Lessner, Nicholas Liebmann, Torsten Liermann, Per Lindqvist, Thomas Runge, Tatu Holzem, Olaf Klein, Leif Jensen, Bart Jourquin, Guilhem Lavaux, Jan Lessner, Nicholas Liebmann, Torsten Liermann, Per Lindqvist, Thomas Runge, Tatu
M\"{a}nnist\"{o}, Scott Maxwell, Thomas Myers, Oliver Niedung, Hernan Otero, Ian Perrigo, Timothy Peters, Giordano Pezzoli, Harri Pasanen, Thomaso Paoletti, M\"{a}nnist\"{o}, Scott Maxwell, Thomas Myers, Oliver Niedung, Hernan Otero, Ian Perrigo, Timothy Peters, Giordano Pezzoli, Harri Pasanen, Thomaso Paoletti,
Garrett Potts, Marcel Rasche, Robert Roebling, Dino Scaringella, Jobst Schmalenbach, Arthur Seaton, Paul Shirley, Stein Somers, Petr Smilauer, Neil Smith, Garrett Potts, Marcel Rasche, Robert Roebling, Dino Scaringella, Jobst Schmalenbach, Arthur Seaton, Paul Shirley, Vaclav Slavik, Stein Somers, Petr Smilauer, Neil Smith,
Kari Syst\"{a}, Arthur Tetzlaff-Deas, Jonathan Tonberg, Jyrki Tuomi, Janos Vegh, Andrea Venturoli, Vadim Zeitlin, Xiaokun Zhu, Edward Zimmermann. Kari Syst\"{a}, Arthur Tetzlaff-Deas, Jonathan Tonberg, Jyrki Tuomi, Janos Vegh, Andrea Venturoli, Vadim Zeitlin, Xiaokun Zhu, Edward Zimmermann.
`Graphplace', the basis for the wxGraphLayout library, is copyright Dr. Jos `Graphplace', the basis for the wxGraphLayout library, is copyright Dr. Jos

View File

@@ -6,7 +6,7 @@
\section{\class{wxHtmlCell}}\label{wxhtmlcell} \section{\class{wxHtmlCell}}\label{wxhtmlcell}
Internal data structure. It represents fragments of parsed HTML Internal data structure. It represents fragments of parsed HTML
page, so-called {\bf cell} - a word, picture, table, horizontal line and so on. page, the so-called {\bf cell} - a word, picture, table, horizontal line and so on.
It is used by \helpref{wxHtmlWindow}{wxhtmlwindow} and It is used by \helpref{wxHtmlWindow}{wxhtmlwindow} and
\helpref{wxHtmlWinParser}{wxhtmlwinparser} to represent HTML page in memory. \helpref{wxHtmlWinParser}{wxhtmlwinparser} to represent HTML page in memory.
@@ -31,7 +31,6 @@ wxObject
Constructor. Constructor.
\membersection{wxHtmlCell::AdjustPagebreak}\label{wxhtmlcelladjustpagebreak} \membersection{wxHtmlCell::AdjustPagebreak}\label{wxhtmlcelladjustpagebreak}
\func{virtual bool}{AdjustPagebreak}{\param{int * }{pagebreak}} \func{virtual bool}{AdjustPagebreak}{\param{int * }{pagebreak}}
@@ -107,11 +106,11 @@ HTML_COND_ISANCHOR condition)
\wxheading{Defined conditions} \wxheading{Defined conditions}
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML_COND_ISANCHOR}}{Finds particular anchor. \twocolitem{{\bf HTML_COND_ISANCHOR}}{Finds particular anchor.
{\it param} is pointer to wxString with name of the anchor.} {\it param} is pointer to wxString with name of the anchor.}
\twocolitem{{\bf HTML_COND_USER}}{User-defined conditions start \twocolitem{{\bf HTML_COND_USER}}{User-defined conditions start
from this number} from this number.}
\end{twocollist} \end{twocollist}
\membersection{wxHtmlCell::GetDescent}\label{wxhtmlcellgetdescent} \membersection{wxHtmlCell::GetDescent}\label{wxhtmlcellgetdescent}
@@ -182,7 +181,7 @@ Returns width of the cell (m_Width member).
This method performs 2 actions: This method performs 2 actions:
\begin{enumerate} \begin{enumerate}\itemsep=0pt
\item adjusts cell's width according to the fact that maximal possible width is {\it w}. \item adjusts cell's width according to the fact that maximal possible width is {\it w}.
(this has sense when working with horizontal lines, tables etc.) (this has sense when working with horizontal lines, tables etc.)
\item prepares layout (=fill-in m\_PosX, m\_PosY (and sometimes m\_Height) members) \item prepares layout (=fill-in m\_PosX, m\_PosY (and sometimes m\_Height) members)
@@ -240,5 +239,5 @@ Sets parent container of this cell. This is called from
\func{void}{SetPos}{\param{int }{x}, \param{int }{y}} \func{void}{SetPos}{\param{int }{x}, \param{int }{y}}
Sets cell's position within parent container. Sets the cell's position within parent container.

View File

@@ -25,10 +25,9 @@ Constructor.
\docparam{flags}{Can be one of following: \docparam{flags}{Can be one of following:
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_CLR\_FOREGROUND}}{change color of text} \twocolitem{{\bf HTML\_CLR\_FOREGROUND}}{change color of text}
\twocolitem{{\bf HTML\_CLR\_BACKGROUND}}{change background color} \twocolitem{{\bf HTML\_CLR\_BACKGROUND}}{change background color}
\end{twocollist} \end{twocollist}
} }

View File

@@ -5,7 +5,7 @@
\section{\class{wxHtmlContainerCell}}\label{wxhtmlcontainercell} \section{\class{wxHtmlContainerCell}}\label{wxhtmlcontainercell}
wxHtmlContainerCell class an implementation of a cell that may The wxHtmlContainerCell class is an implementation of a cell that may
contain more cells in it. It is heavily used in the wxHTML layout algorithm. contain more cells in it. It is heavily used in the wxHTML layout algorithm.
\wxheading{Derived from} \wxheading{Derived from}
@@ -45,7 +45,7 @@ Returns pointer to the first cell in the list.
You can then use wxHtmlCell's GetNext method to obtain pointer to the next You can then use wxHtmlCell's GetNext method to obtain pointer to the next
cell in list. cell in list.
{\bf Note} : This shouldn't be used by the end user. If you need some way of {\bf Note:} This shouldn't be used by the end user. If you need some way of
finding particular cell in the list, try \helpref{Find}{wxhtmlcellfind} method finding particular cell in the list, try \helpref{Find}{wxhtmlcellfind} method
instead. instead.
@@ -63,10 +63,9 @@ It is NOT always in pixels!
\constfunc{int}{GetIndentUnits}{\param{int }{ind}} \constfunc{int}{GetIndentUnits}{\param{int }{ind}}
Returns units of intentation value for {\it ind} where {\it ind} is one Returns the units of indentation for {\it ind} where {\it ind} is one
of the {\bf HTML\_INDENT\_*} constants. of the {\bf HTML\_INDENT\_*} constants.
\membersection{wxHtmlContainerCell::GetMaxLineWidth}\label{wxhtmlcontainercellgetmaxlinewidth} \membersection{wxHtmlContainerCell::GetMaxLineWidth}\label{wxhtmlcontainercellgetmaxlinewidth}
\constfunc{int}{GetMaxLineWidth}{\void} \constfunc{int}{GetMaxLineWidth}{\void}
@@ -86,42 +85,40 @@ Inserts new cell into the container.
\func{void}{SetAlign}{\param{const wxHtmlTag\& }{tag}} \func{void}{SetAlign}{\param{const wxHtmlTag\& }{tag}}
Sets container's alignment (both horizontal and vertical) according to Sets the container's alignment (both horizontal and vertical) according to
the values stored in {\it tag}. (Tags {\tt ALIGN} parameter is extracted.) In fact the values stored in {\it tag}. (Tags {\tt ALIGN} parameter is extracted.) In fact
it is only a front-end to \helpref{SetAlignHor}{wxhtmlcontainercellsetalignhor} it is only a front-end to \helpref{SetAlignHor}{wxhtmlcontainercellsetalignhor}
and \helpref{SetAlignVer}{wxhtmlcontainercellsetalignver}. and \helpref{SetAlignVer}{wxhtmlcontainercellsetalignver}.
\membersection{wxHtmlContainerCell::SetAlignHor}\label{wxhtmlcontainercellsetalignhor} \membersection{wxHtmlContainerCell::SetAlignHor}\label{wxhtmlcontainercellsetalignhor}
\func{void}{SetAlignHor}{\param{int }{al}} \func{void}{SetAlignHor}{\param{int }{al}}
Sets container's {\it horizontal alignment}. During \helpref{Layout}{wxhtmlcelllayout} Sets the container's {\it horizontal alignment}. During \helpref{Layout}{wxhtmlcelllayout}
each line is aligned according to {\it al} value. each line is aligned according to {\it al} value.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{al}{new horizontal alignment. May be one of these values: \docparam{al}{new horizontal alignment. May be one of these values:
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_ALIGN\_LEFT}}{lines are left-aligned (default)} \twocolitem{{\bf HTML\_ALIGN\_LEFT}}{lines are left-aligned (default)}
\twocolitem{{\bf HTML\_ALIGN\_CENTER\_H}}{lines are centered} \twocolitem{{\bf HTML\_ALIGN\_CENTER\_H}}{lines are centered}
\twocolitem{{\bf HTML\_ALIGN\_RIGHT}}{lines are right-aligned} \twocolitem{{\bf HTML\_ALIGN\_RIGHT}}{lines are right-aligned}
\end{twocollist} \end{twocollist}
} }
\membersection{wxHtmlContainerCell::SetAlignVer}\label{wxhtmlcontainercellsetalignver} \membersection{wxHtmlContainerCell::SetAlignVer}\label{wxhtmlcontainercellsetalignver}
\func{void}{SetAlignVer}{\param{int }{al}} \func{void}{SetAlignVer}{\param{int }{al}}
Sets container's {\it vertical alignment}. This is per-line alignment! Sets the container's {\it vertical alignment}. This is per-line alignment!
\wxheading{Parameters} \wxheading{Parameters}
\docparam{al}{new vertical alignment. May be one of these values: \docparam{al}{new vertical alignment. May be one of these values:
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_ALIGN\_BOTTOM}}{cells are over the line (default)} \twocolitem{{\bf HTML\_ALIGN\_BOTTOM}}{cells are over the line (default)}
\twocolitem{{\bf HTML\_ALIGN\_CENTER\_V}}{cells are centered on line} \twocolitem{{\bf HTML\_ALIGN\_CENTER\_V}}{cells are centered on line}
\twocolitem{{\bf HTML\_ALIGN\_TOP}}{cells are under the line} \twocolitem{{\bf HTML\_ALIGN\_TOP}}{cells are under the line}
@@ -134,13 +131,13 @@ Sets container's {\it vertical alignment}. This is per-line alignment!
\func{void}{SetBackgroundColour}{\param{const wxColour\& }{clr}} \func{void}{SetBackgroundColour}{\param{const wxColour\& }{clr}}
Sets background color for this container. Sets the background color for this container.
\membersection{wxHtmlContainerCell::SetBorder}\label{wxhtmlcontainercellsetborder} \membersection{wxHtmlContainerCell::SetBorder}\label{wxhtmlcontainercellsetborder}
\func{void}{SetBorder}{\param{const wxColour\& }{clr1}, \param{const wxColour\& }{clr2}} \func{void}{SetBorder}{\param{const wxColour\& }{clr1}, \param{const wxColour\& }{clr2}}
Sets border (frame) colours. Border is rectangle around the container. Sets the border (frame) colours. Border is rectangle around the container.
\wxheading{Parameters} \wxheading{Parameters}
@@ -152,16 +149,16 @@ Sets border (frame) colours. Border is rectangle around the container.
\func{void}{SetIndent}{\param{int }{i}, \param{int }{what}, \param{int }{units = HTML\_UNITS\_PIXELS}} \func{void}{SetIndent}{\param{int }{i}, \param{int }{what}, \param{int }{units = HTML\_UNITS\_PIXELS}}
Sets indentation (free space between borders of container and subcells). Sets the indentation (free space between borders of container and subcells).
\wxheading{Parameters} \wxheading{Parameters}
\docparam{i}{Indentation value.} \docparam{i}{Indentation value.}
\docparam{what}{Determines which of the 4 borders we're setting. It is OR \docparam{what}{Determines which of the four borders we're setting. It is OR
combination of following constants: combination of following constants:
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_INDENT\_TOP}}{top border} \twocolitem{{\bf HTML\_INDENT\_TOP}}{top border}
\twocolitem{{\bf HTML\_INDENT\_BOTTOM}}{bottom} \twocolitem{{\bf HTML\_INDENT\_BOTTOM}}{bottom}
\twocolitem{{\bf HTML\_INDENT\_LEFT}}{left} \twocolitem{{\bf HTML\_INDENT\_LEFT}}{left}
@@ -176,7 +173,7 @@ combination of following constants:
\docparam{units}{Units of {\it i}. This parameter affects interpretation of {\it} value. \docparam{units}{Units of {\it i}. This parameter affects interpretation of {\it} value.
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_UNITS\_PIXELS}}{{\it i} is number of pixels} \twocolitem{{\bf HTML\_UNITS\_PIXELS}}{{\it i} is number of pixels}
\twocolitem{{\bf HTML\_UNITS\_PERCENT}}{{\it i} is interpreted as percents of width \twocolitem{{\bf HTML\_UNITS\_PERCENT}}{{\it i} is interpreted as percents of width
of parent container} of parent container}
@@ -189,17 +186,17 @@ of parent container}
Sets minimal height of the container. Sets minimal height of the container.
(When container's \helpref{Layout}{wxhtmlcelllayout} is called, m_Height When container's \helpref{Layout}{wxhtmlcelllayout} is called, m\_Height
is set depending on layout of subcells to the height of area covered is set depending on layout of subcells to the height of area covered
by layouted subcells. Call to this method guarantees you that the height by layed-out subcells. Calling this method guarantees you that the height
of container is never smaller than {\it h} - even if the subcells cover of container is never smaller than {\it h} - even if the subcells cover
much smaller area.) much smaller area.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{h}{The minimal height.} \docparam{h}{The minimal height.}
\docparam{align}{If height of the container is lower than min. height, empty space must be inserted \docparam{align}{If height of the container is lower than the minimum height, empty space must be inserted
somewhere in order to ensure minimal height. This parameter is one of {\bf HTML_ALIGN_TOP, somewhere in order to ensure minimal height. This parameter is one of {\bf HTML_ALIGN_TOP,
HTML_ALIGN_BOTTOM, HTML_ALIGN_CENTER} constants. It refers to the {\it contents}, not to the HTML_ALIGN_BOTTOM, HTML_ALIGN_CENTER} constants. It refers to the {\it contents}, not to the
empty place!} empty place!}
@@ -212,7 +209,7 @@ empty place!}
Sets floating width adjustment. Sets floating width adjustment.
Normal behaviour of container is that it's width is same as width of The normal behaviour of container is that its width is the same as the width of
parent container (and thus you can have only one sub-container per line). parent container (and thus you can have only one sub-container per line).
You can change this by setting FWA. You can change this by setting FWA.
@@ -224,9 +221,9 @@ complement to full width of parent container (e.g.
of container to parent's width minus 50 pixels. This is useful when of container to parent's width minus 50 pixels. This is useful when
creating tables - you can call SetWidthFloat(50) and SetWidthFloat(-50))} creating tables - you can call SetWidthFloat(50) and SetWidthFloat(-50))}
\docparam{units}{Units of {\it w} This parameter affects interpretation of {\it} value. \docparam{units}{Units of {\it w} This parameter affects the interpretation of {\it} value.
\begin{twocollist} \begin{twocollist}\itemsep=0pt
\twocolitem{{\bf HTML\_UNITS\_PIXELS}}{{\it w} is number of pixels} \twocolitem{{\bf HTML\_UNITS\_PIXELS}}{{\it w} is number of pixels}
\twocolitem{{\bf HTML\_UNITS\_PERCENT}}{{\it w} is interpreted as percents of width \twocolitem{{\bf HTML\_UNITS\_PERCENT}}{{\it w} is interpreted as percents of width
of parent container} of parent container}
@@ -236,4 +233,3 @@ of parent container}
\docparam{tag}{In the second version of method, {\it w} and {\it units} \docparam{tag}{In the second version of method, {\it w} and {\it units}
info is extracted from tag's {\tt WIDTH} parameter.} info is extracted from tag's {\tt WIDTH} parameter.}

View File

@@ -3,30 +3,24 @@
% htmprint.h at 17/Oct/99 12:48:02 % htmprint.h at 17/Oct/99 12:48:02
% %
\section{\class{wxHtmlDCRenderer}}\label{wxhtmldcrenderer} \section{\class{wxHtmlDCRenderer}}\label{wxhtmldcrenderer}
This class can render HTML document into specified area of DC. You can use it This class can render HTML document into a specified area of a DC. You can use it
in your own printing code, although use of \helpref{wxHtmlEasyPrinting}{wxhtmleasyprinting} in your own printing code, although use of \helpref{wxHtmlEasyPrinting}{wxhtmleasyprinting}
or \helpref{wxHtmlPrintout}{wxhtmlprintout} is strongly recommended. or \helpref{wxHtmlPrintout}{wxhtmlprintout} is strongly recommended.
\wxheading{Derived from} \wxheading{Derived from}
\helpref{wxObject}{wxobject} \helpref{wxObject}{wxobject}
\latexignore{\rtfignore{\wxheading{Members}}} \latexignore{\rtfignore{\wxheading{Members}}}
\membersection{wxHtmlDCRenderer::wxHtmlDCRenderer}\label{wxhtmldcrendererwxhtmldcrenderer} \membersection{wxHtmlDCRenderer::wxHtmlDCRenderer}\label{wxhtmldcrendererwxhtmldcrenderer}
\func{}{wxHtmlDCRenderer}{\void} \func{}{wxHtmlDCRenderer}{\void}
Constructor. Constructor.
\membersection{wxHtmlDCRenderer::SetDC}\label{wxhtmldcrenderersetdc} \membersection{wxHtmlDCRenderer::SetDC}\label{wxhtmldcrenderersetdc}
\func{void}{SetDC}{\param{wxDC* }{dc}, \param{int }{maxwidth}} \func{void}{SetDC}{\param{wxDC* }{dc}, \param{int }{maxwidth}}
@@ -38,13 +32,11 @@ Assign DC instance to the renderer.
\docparam{maxwidth}{width of the area (on this DC) that is equivalent to screen's width, \docparam{maxwidth}{width of the area (on this DC) that is equivalent to screen's width,
in pixels (you should set it to page width minus margins). in pixels (you should set it to page width minus margins).
{\bf Note:} In current implementation {\bf Note:} In the current implementation
screen width is always 800 pixels : it gives best results and ensures (almost) same printed outputs the screen width is always 800 pixels: it gives best results and ensures (almost) same printed outputs
across platforms and differently configured desktops.} across platforms and differently configured desktops.}
Also see \helpref{SetSize}{wxhtmldcrenderersetsize} See also \helpref{SetSize}{wxhtmldcrenderersetsize}.
\membersection{wxHtmlDCRenderer::SetSize}\label{wxhtmldcrenderersetsize} \membersection{wxHtmlDCRenderer::SetSize}\label{wxhtmldcrenderersetsize}
@@ -57,7 +49,6 @@ If you set width equal to maxwidth then HTML is rendered as if it were displayed
If you set width = 1/2 maxwidth the it is rendered as if it covered half the screen If you set width = 1/2 maxwidth the it is rendered as if it covered half the screen
and so on. and so on.
\membersection{wxHtmlDCRenderer::SetHtmlText}\label{wxhtmldcrenderersethtmltext} \membersection{wxHtmlDCRenderer::SetHtmlText}\label{wxhtmldcrenderersethtmltext}
\func{void}{SetHtmlText}{\param{const wxString\& }{html}, \param{const wxString\& }{basepath = wxEmptyString}, \param{bool }{isdir = TRUE}} \func{void}{SetHtmlText}{\param{const wxString\& }{html}, \param{const wxString\& }{basepath = wxEmptyString}, \param{bool }{isdir = TRUE}}
@@ -65,10 +56,9 @@ and so on.
Assign text to the renderer. \helpref{Render}{wxhtmldcrendererrender} then draws Assign text to the renderer. \helpref{Render}{wxhtmldcrendererrender} then draws
the text onto DC. the text onto DC.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{html}{HTML text. (NOT file!)} \docparam{html}{HTML text. This is {\it not} a filename.}
\docparam{basepath}{base directory (html string would be stored there if it was in \docparam{basepath}{base directory (html string would be stored there if it was in
file). It is used to determine path for loading images, for example.} file). It is used to determine path for loading images, for example.}
@@ -76,7 +66,6 @@ file). It is used to determine path for loading images, for example.}
\docparam{isdir}{FALSE if basepath is filename, TRUE if it is directory name \docparam{isdir}{FALSE if basepath is filename, TRUE if it is directory name
(see \helpref{wxFileSystem}{wxfilesystem} for detailed explanation)} (see \helpref{wxFileSystem}{wxfilesystem} for detailed explanation)}
\membersection{wxHtmlDCRenderer::Render}\label{wxhtmldcrendererrender} \membersection{wxHtmlDCRenderer::Render}\label{wxhtmldcrendererrender}
\func{int}{Render}{\param{int }{x}, \param{int }{y}, \param{int }{from = 0}, \param{int }{dont\_render = FALSE}} \func{int}{Render}{\param{int }{x}, \param{int }{y}, \param{int }{from = 0}, \param{int }{dont\_render = FALSE}}
@@ -85,10 +74,8 @@ Renders HTML text to the DC.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{x,y}{ position of upper-left corner of printing rectangle (see \helpref{SetSize}{wxhtmldcrenderersetsize})} \docparam{x,y}{ position of upper-left corner of printing rectangle (see \helpref{SetSize}{wxhtmldcrenderersetsize})}
\docparam{from}{y-coordinate of the very first visible cell} \docparam{from}{y-coordinate of the very first visible cell}
\docparam{dont\_render}{if TRUE then this method only returns y coordinate of the next page \docparam{dont\_render}{if TRUE then this method only returns y coordinate of the next page
@@ -98,32 +85,24 @@ Returned value is y coordinate of first cell than didn't fit onto page.
Use this value as {\it from} in next call to Render in order to print multipages Use this value as {\it from} in next call to Render in order to print multipages
document. document.
\wxheading{Caution!} \wxheading{Caution!}
Following 3 methods {\bf must} always be called before any call to Render (preferably The Following three methods {\bf must} always be called before any call to Render (preferably
in this order): in this order):
\begin{itemize} \begin{itemize}\itemsep=0pt
\item \helpref{SetDC}{wxhtmldcrenderersetdc} \item \helpref{SetDC}{wxhtmldcrenderersetdc}
\item \helpref{SetSize}{wxhtmldcrenderersetsize} \item \helpref{SetSize}{wxhtmldcrenderersetsize}
\item \helpref{SetHtmlText}{wxhtmldcrenderersethtmltext} \item \helpref{SetHtmlText}{wxhtmldcrenderersethtmltext}
\end{itemize} \end{itemize}
{\bf Render() changes DC's user scale and does NOT restore it!!} {\bf Render() changes the DC's user scale and does NOT restore it.}
\membersection{wxHtmlDCRenderer::GetTotalHeight}\label{wxhtmldcrenderergettotalheight} \membersection{wxHtmlDCRenderer::GetTotalHeight}\label{wxhtmldcrenderergettotalheight}
\func{int}{GetTotalHeight}{\void} \func{int}{GetTotalHeight}{\void}
Returns height of the HTML text. This is important if area height (see \helpref{SetSize}{wxhtmldcrenderersetsize}) Returns the height of the HTML text. This is important if area height (see \helpref{SetSize}{wxhtmldcrenderersetsize})
is smaller that total height and thus the page cannot fit into it. In that case you're supposed to is smaller that total height and thus the page cannot fit into it. In that case you're supposed to
call \helpref{Render}{wxhtmldcrendererrender} as long as it's return value is smaller than GetTotalHeight's. call \helpref{Render}{wxhtmldcrendererrender} as long as its return value is smaller than GetTotalHeight's.

View File

@@ -3,29 +3,24 @@
% htmprint.h at 17/Oct/99 12:48:02 % htmprint.h at 17/Oct/99 12:48:02
% %
\section{\class{wxHtmlEasyPrinting}}\label{wxhtmleasyprinting} \section{\class{wxHtmlEasyPrinting}}\label{wxhtmleasyprinting}
This class provides very simple interface to printing This class provides very simple interface to printing
architecture. It allows you to print HTML documents only architecture. It allows you to print HTML documents using
with very few commands. only a few commands.
\wxheading{Note} \wxheading{Note}
Do not create this class on stack only. You should create an instance on app
Do not create this class on the stack only. You should create an instance on app
startup and use this instance for all printing operations. The reason is that startup and use this instance for all printing operations. The reason is that
this class stores various settings in it. this class stores various settings in it.
\wxheading{Derived from} \wxheading{Derived from}
\helpref{wxObject}{wxobject} \helpref{wxObject}{wxobject}
\latexignore{\rtfignore{\wxheading{Members}}} \latexignore{\rtfignore{\wxheading{Members}}}
\membersection{wxHtmlEasyPrinting::wxHtmlEasyPrinting}\label{wxhtmleasyprintingwxhtmleasyprinting} \membersection{wxHtmlEasyPrinting::wxHtmlEasyPrinting}\label{wxhtmleasyprintingwxhtmleasyprinting}
\func{}{wxHtmlEasyPrinting}{\param{const wxString\& }{name = "Printing"}, \param{wxFrame* }{parent\_frame = NULL}} \func{}{wxHtmlEasyPrinting}{\param{const wxString\& }{name = "Printing"}, \param{wxFrame* }{parent\_frame = NULL}}
@@ -39,14 +34,12 @@ Constructor.
\docparam{parent\_frame}{pointer to the frame that will own preview frame and setup dialogs. May be NULL.} \docparam{parent\_frame}{pointer to the frame that will own preview frame and setup dialogs. May be NULL.}
\membersection{wxHtmlEasyPrinting::PreviewFile}\label{wxhtmleasyprintingpreviewfile} \membersection{wxHtmlEasyPrinting::PreviewFile}\label{wxhtmleasyprintingpreviewfile}
\func{void}{PreviewFile}{\param{const wxString\& }{htmlfile}} \func{void}{PreviewFile}{\param{const wxString\& }{htmlfile}}
Previews HTML file. Previews HTML file.
\membersection{wxHtmlEasyPrinting::PreviewText}\label{wxhtmleasyprintingpreviewtext} \membersection{wxHtmlEasyPrinting::PreviewText}\label{wxhtmleasyprintingpreviewtext}
\func{void}{PreviewText}{\param{const wxString\& }{htmltext}, \param{const wxString\& }{basepath = wxEmptyString}} \func{void}{PreviewText}{\param{const wxString\& }{htmltext}, \param{const wxString\& }{basepath = wxEmptyString}}
@@ -60,15 +53,12 @@ Previews HTML text (not file!).
\docparam{basepath}{base directory (html string would be stored there if it was in \docparam{basepath}{base directory (html string would be stored there if it was in
file). It is used to determine path for loading images, for example.} file). It is used to determine path for loading images, for example.}
\membersection{wxHtmlEasyPrinting::PrintFile}\label{wxhtmleasyprintingprintfile} \membersection{wxHtmlEasyPrinting::PrintFile}\label{wxhtmleasyprintingprintfile}
\func{void}{PrintFile}{\param{const wxString\& }{htmlfile}} \func{void}{PrintFile}{\param{const wxString\& }{htmlfile}}
Prints HTML file. Prints HTML file.
\membersection{wxHtmlEasyPrinting::PrintText}\label{wxhtmleasyprintingprinttext} \membersection{wxHtmlEasyPrinting::PrintText}\label{wxhtmleasyprintingprinttext}
\func{void}{PrintText}{\param{const wxString\& }{htmltext}, \param{const wxString\& }{basepath = wxEmptyString}} \func{void}{PrintText}{\param{const wxString\& }{htmltext}, \param{const wxString\& }{basepath = wxEmptyString}}
@@ -82,21 +72,18 @@ Prints HTML text (not file!).
\docparam{basepath}{base directory (html string would be stored there if it was in \docparam{basepath}{base directory (html string would be stored there if it was in
file). It is used to determine path for loading images, for example.} file). It is used to determine path for loading images, for example.}
\membersection{wxHtmlEasyPrinting::PrinterSetup}\label{wxhtmleasyprintingprintersetup} \membersection{wxHtmlEasyPrinting::PrinterSetup}\label{wxhtmleasyprintingprintersetup}
\func{void}{PrinterSetup}{\void} \func{void}{PrinterSetup}{\void}
Displays printer setup dialog and allows the user to modify settings. Displays printer setup dialog and allows the user to modify settings.
\membersection{wxHtmlEasyPrinting::PageSetup}\label{wxhtmleasyprintingpagesetup} \membersection{wxHtmlEasyPrinting::PageSetup}\label{wxhtmleasyprintingpagesetup}
\func{void}{PageSetup}{\void} \func{void}{PageSetup}{\void}
Displays page setup dialog and allows the user to modify settings. Displays page setup dialog and allows the user to modify settings.
\membersection{wxHtmlEasyPrinting::SetHeader}\label{wxhtmleasyprintingsetheader} \membersection{wxHtmlEasyPrinting::SetHeader}\label{wxhtmleasyprintingsetheader}
\func{void}{SetHeader}{\param{const wxString\& }{header}, \param{int }{pg = wxPAGE\_ALL}} \func{void}{SetHeader}{\param{const wxString\& }{header}, \param{int }{pg = wxPAGE\_ALL}}
@@ -106,7 +93,8 @@ Sets page header.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{header}{HTML text to be used as header. You can use macros in it: \docparam{header}{HTML text to be used as header. You can use macros in it:
\begin{itemize}
\begin{itemize}\itemsep=0pt
\item @PAGENUM@ is replaced by page number \item @PAGENUM@ is replaced by page number
\item @PAGESCNT@ is replaced by total number of pages \item @PAGESCNT@ is replaced by total number of pages
\end{itemize} \end{itemize}
@@ -114,7 +102,6 @@ Sets page header.
\docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.} \docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.}
\membersection{wxHtmlEasyPrinting::SetFooter}\label{wxhtmleasyprintingsetfooter} \membersection{wxHtmlEasyPrinting::SetFooter}\label{wxhtmleasyprintingsetfooter}
\func{void}{SetFooter}{\param{const wxString\& }{footer}, \param{int }{pg = wxPAGE\_ALL}} \func{void}{SetFooter}{\param{const wxString\& }{footer}, \param{int }{pg = wxPAGE\_ALL}}
@@ -124,18 +111,15 @@ Sets page footer.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{footer}{HTML text to be used as footer. You can use macros in it: \docparam{footer}{HTML text to be used as footer. You can use macros in it:
\begin{itemize}
\begin{itemize}\itemsep=0pt
\item @PAGENUM@ is replaced by page number \item @PAGENUM@ is replaced by page number
\item @PAGESCNT@ is replaced by total number of pages \item @PAGESCNT@ is replaced by total number of pages
\end{itemize} \end{itemize}
} }
\docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.} \docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.}
\membersection{wxHtmlEasyPrinting::GetPrintData}\label{wxhtmleasyprintinggetprintdata} \membersection{wxHtmlEasyPrinting::GetPrintData}\label{wxhtmleasyprintinggetprintdata}
\func{wxPrintData*}{GetPrintData}{\void} \func{wxPrintData*}{GetPrintData}{\void}
@@ -147,5 +131,6 @@ set its parameters (via SetXXXX methods).
\func{wxPageSetupDialogData*}{GetPageSetupData}{\void} \func{wxPageSetupDialogData*}{GetPageSetupData}{\void}
Returns pointer to \helpref{wxPageSetupDialogData}{wxpagesetupdialogdata} instance used by Returns a pointer to \helpref{wxPageSetupDialogData}{wxpagesetupdialogdata} instance used by
this class. You can set its parameters (via SetXXXX methods). this class. You can set its parameters (via SetXXXX methods).

View File

@@ -5,7 +5,7 @@
\section{\class{wxHtmlFilter}}\label{wxhtmlfilter} \section{\class{wxHtmlFilter}}\label{wxhtmlfilter}
This class is input filter for \helpref{wxHtmlWindow}{wxhtmlwindow}. This class is an input filter for \helpref{wxHtmlWindow}{wxhtmlwindow}.
It allows you to read and display files of different file formats. It allows you to read and display files of different file formats.
\wxheading{Derived from} \wxheading{Derived from}

View File

@@ -8,11 +8,11 @@
{\bf WARNING! This help controller has an API incompatible with wxWindows {\bf WARNING! This help controller has an API incompatible with wxWindows
wxHelpController!} wxHelpController!}
This help controller provides easy way how to display HTML help in your This help controller provides an easy way of displaying HTML help in your
application (see {\it test} sample). Whole help system is based on {\bf books} application (see {\it test} sample). The help system is based on {\bf books}
(see \helpref{AddBook}{wxhtmlhelpcontrolleraddbook}). A book is logical (see \helpref{AddBook}{wxhtmlhelpcontrolleraddbook}). A book is a logical
part of documentation (for example "User's Guide" or "Programmer's Guide" or section of documentation (for example "User's Guide" or "Programmer's Guide" or
"C++ Reference" or "wxWindows Reference"). Help controller can handle as "C++ Reference" or "wxWindows Reference"). The help controller can handle as
many books as you want. many books as you want.
wxHTML uses Microsoft's HTML Help Workshop project files (.hhp, .hhk, .hhc) as its wxHTML uses Microsoft's HTML Help Workshop project files (.hhp, .hhk, .hhc) as its
@@ -22,7 +22,7 @@ Have a look at docs/html/ directory where sample project files are stored.
You can use tex2rtf to generate MHHW projects (see wxHTML homepage for details). You can use tex2rtf to generate MHHW projects (see wxHTML homepage for details).
In order to use the controller in your application under Windows you must In order to use the controller in your application under Windows you must
have following line in your .rc file: have the following line in your .rc file:
\begin{verbatim} \begin{verbatim}
#include "wx/html/msw/wxhtml.rc" #include "wx/html/msw/wxhtml.rc"
@@ -47,7 +47,7 @@ Constructor.
Adds book (\helpref{.hhp file}{helpformat} - HTML Help Workshop project file) into the list of loaded books. Adds book (\helpref{.hhp file}{helpformat} - HTML Help Workshop project file) into the list of loaded books.
This must be called at least once before displaying any help. This must be called at least once before displaying any help.
If {\it show_wait_msg} is TRUE then a decorationless window with progress message is displayed. If {\it show\_wait\_msg} is TRUE then a decorationless window with progress message is displayed.
\membersection{wxHtmlHelpController::Display}\label{wxhtmlhelpcontrollerdisplay} \membersection{wxHtmlHelpController::Display}\label{wxhtmlhelpcontrollerdisplay}
@@ -58,7 +58,7 @@ the help in application.
You can specify the page in many ways: You can specify the page in many ways:
\begin{itemize} \begin{itemize}\itemsep=0pt
\item as direct filename of HTML document \item as direct filename of HTML document
\item as chapter name (from contents) or as a book name \item as chapter name (from contents) or as a book name
\item as some word from index \item as some word from index
@@ -67,7 +67,7 @@ You can specify the page in many ways:
Looking for the page runs in these steps: Looking for the page runs in these steps:
\begin{enumerate} \begin{enumerate}\itemsep=0pt
\item try to locate file named x (if x is for example "doc/howto.htm") \item try to locate file named x (if x is for example "doc/howto.htm")
\item try to open starting page of book named x \item try to open starting page of book named x
\item try to find x in contents (if x is for example "How To ...") \item try to find x in contents (if x is for example "How To ...")
@@ -98,23 +98,23 @@ Displays help window and focuses index panel.
Displays help window, focuses search panel and starts searching. Displays help window, focuses search panel and starts searching.
Returns TRUE if the keyword was found. Returns TRUE if the keyword was found.
IMPORTANT! KeywordSearch searches only pages listed in .htc file(s)! {\bf Important:} KeywordSearch searches only pages listed in .htc file(s).
(you should have all pages in contents file...) You should list all pages in the contents file.
\membersection{wxHtmlHelpController::ReadCustomization}\label{wxhtmlhelpcontrollerreadcustomization} \membersection{wxHtmlHelpController::ReadCustomization}\label{wxhtmlhelpcontrollerreadcustomization}
\func{void}{ReadCustomization}{\param{wxConfigBase* }{cfg}, \param{wxString }{path = wxEmptyString}} \func{void}{ReadCustomization}{\param{wxConfigBase* }{cfg}, \param{wxString }{path = wxEmptyString}}
Reads controllers setting (position of window etc.) Reads the controller's setting (position of window, etc.)
\membersection{wxHtmlHelpController::SetTempDir}\label{wxhtmlhelpcontrollersettempdir} \membersection{wxHtmlHelpController::SetTempDir}\label{wxhtmlhelpcontrollersettempdir}
\func{void}{SetTempDir}{\param{const wxString\& }{path}} \func{void}{SetTempDir}{\param{const wxString\& }{path}}
Sets path for storing temporary files (cached binary versions of index and contents files. These binary Sets the path for storing temporary files - cached binary versions of index and contents files. These binary
forms are much faster to read.) Default value is empty string (empty string means forms are much faster to read. Default value is empty string (empty string means
that no cached data are stored). Note that these files are NOT that no cached data are stored). Note that these files are {\it not}
deleted when program exits! deleted when program exits.
\membersection{wxHtmlHelpController::SetTitleFormat}\label{wxhtmlhelpcontrollersettitleformat} \membersection{wxHtmlHelpController::SetTitleFormat}\label{wxhtmlhelpcontrollersettitleformat}

View File

@@ -1,11 +1,11 @@
\membersection{Tag Handlers}\label{handlers} \membersection{Tag Handlers}\label{handlers}
wxHTML library provides architecture of pluginable {\it tag handlers}. The wxHTML library provides architecture of pluggable {\it tag handlers}.
Tag handler is class that understands particular HTML tag (or tags) and is Tag handler is class that understands particular HTML tag (or tags) and is
able to interpret it. able to interpret it.
\helpref{wxHtmlWinParser}{wxhtmlwinparser} has static table of {\bf modules}. \helpref{wxHtmlWinParser}{wxhtmlwinparser} has static table of {\bf modules}.
Each module contains one or more tag handlers. Each time new wxHtmlWinParser Each module contains one or more tag handlers. Each time a new wxHtmlWinParser
object is constructed all modules are scanned and handlers are added object is constructed all modules are scanned and handlers are added
to wxHtmlParser's list of available handlers (note: wxHtmlParser's list to wxHtmlParser's list of available handlers (note: wxHtmlParser's list
is non-static). is non-static).
@@ -15,7 +15,7 @@ is non-static).
Common tag handler's \helpref{HandleTag}{wxhtmltaghandlerhandletag} method Common tag handler's \helpref{HandleTag}{wxhtmltaghandlerhandletag} method
works in four steps: works in four steps:
\begin{enumerate} \begin{enumerate}\itemsep=0pt
\item Save state of parent parser into local variables \item Save state of parent parser into local variables
\item Change parser state according to tag's params \item Change parser state according to tag's params
\item Parse text between the tag and paired ending tag (if present) \item Parse text between the tag and paired ending tag (if present)
@@ -47,7 +47,7 @@ You can use set of macros to define the handler (see src/mod\_*.cpp files
for details). Handler definition must start with {\bf TAG\_HANDLER\_BEGIN} macro for details). Handler definition must start with {\bf TAG\_HANDLER\_BEGIN} macro
and end with {\bf TAG\_HANDLER\_END} macro. I strongly recommend to have a look and end with {\bf TAG\_HANDLER\_END} macro. I strongly recommend to have a look
at {\it include/wxhtml/mod\_templ.h} file. Otherwise you won't understand at {\it include/wxhtml/mod\_templ.h} file. Otherwise you won't understand
the structure of macros... See macros reference: the structure of macros. See macros reference:
{\bf TAG\_HANDLER\_BEGIN}({\it name}, {\it tags}) {\bf TAG\_HANDLER\_BEGIN}({\it name}, {\it tags})

View File

@@ -4,11 +4,10 @@ The wxHTML library provides printing facilities with several levels of complexit
The easiest way to print an HTML document is to use The easiest way to print an HTML document is to use
\helpref{wxHtmlEasyPrinting class}{wxhtmleasyprinting}. It lets you print HTML documents with only one \helpref{wxHtmlEasyPrinting class}{wxhtmleasyprinting}. It lets you print HTML documents with only one
command and you don't have to care about wxPrintouts etc. at all. It is only simple wrapper around command and you don't have to worry about deriving from the wxPrintout class at all. It is only a simple wrapper around the
\helpref{wxHtmlPrintout}{wxhtmlprintout}, normal wxWindows printout class. \helpref{wxHtmlPrintout}{wxhtmlprintout}, normal wxWindows printout class.
And finally there is the low level class \helpref{wxHtmlDCRenderer}{wxhtmldcrenderer} which you can use to
And finally there is low level class \helpref{wxHtmlDCRenderer}{wxhtmldcrenderer} which you can use to render HTML into a rectangular area on any DC. It supports rendering into multiple rectangles with the same
render HTML into rectangular area on any DC. It supports rendering into multiple rectangles with same width. (The most common use of this is placing one rectangle on each page or printing into two columns.)
width. (Most common use is placing one rectangle on each page or printing into two columns.)

View File

@@ -1,4 +1,4 @@
\membersection{Quick Start}\label{quickstart} \membersection{wxHTML quick start}\label{wxhtmlquickstart}
\wxheading{Displaying HMTL} \wxheading{Displaying HMTL}
@@ -56,7 +56,7 @@ browser's messages (such as "Loading..." or "Done" or hypertext links).
You can customize wxHtmlWindow by setting font size, font face and You can customize wxHtmlWindow by setting font size, font face and
borders (space between border of window and displayed HTML). Related functions: borders (space between border of window and displayed HTML). Related functions:
\begin{itemize} \begin{itemize}\itemsep=0pt
\item \helpref{SetFonts}{wxhtmlwindowsetfonts} \item \helpref{SetFonts}{wxhtmlwindowsetfonts}
\item \helpref{SetBorders}{wxhtmlwindowsetborders} \item \helpref{SetBorders}{wxhtmlwindowsetborders}
\item \helpref{ReadCustomization}{wxhtmlwindowreadcustomization} \item \helpref{ReadCustomization}{wxhtmlwindowreadcustomization}

View File

@@ -164,7 +164,7 @@ call it when you need to obtain parsed output (which is parser-specific)
The method does these things: The method does these things:
\begin{enumerate} \begin{enumerate}\itemsep=0pt
\item calls \helpref{InitParser(source)}{wxhtmlparserinitparser} \item calls \helpref{InitParser(source)}{wxhtmlparserinitparser}
\item calls \helpref{DoParsing}{wxhtmlparserdoparsing} \item calls \helpref{DoParsing}{wxhtmlparserdoparsing}
\item calls \helpref{GetProduct}{wxhtmlparsergetproduct} \item calls \helpref{GetProduct}{wxhtmlparsergetproduct}

View File

@@ -3,27 +3,22 @@
% htmprint.h at 17/Oct/99 12:48:02 % htmprint.h at 17/Oct/99 12:48:02
% %
\section{\class{wxHtmlPrintout}}\label{wxhtmlprintout} \section{\class{wxHtmlPrintout}}\label{wxhtmlprintout}
This class serves as printout class for HTML documents. This class serves as a printout class for HTML documents.
\wxheading{Derived from} \wxheading{Derived from}
\helpref{wxPrintout}{wxprintout} \helpref{wxPrintout}{wxprintout}
\latexignore{\rtfignore{\wxheading{Members}}} \latexignore{\rtfignore{\wxheading{Members}}}
\membersection{wxHtmlPrintout::wxHtmlPrintout}\label{wxhtmlprintoutwxhtmlprintout} \membersection{wxHtmlPrintout::wxHtmlPrintout}\label{wxhtmlprintoutwxhtmlprintout}
\func{}{wxHtmlPrintout}{\param{const wxString\& }{title = "Printout"}} \func{}{wxHtmlPrintout}{\param{const wxString\& }{title = "Printout"}}
Constructor. Constructor.
\membersection{wxHtmlPrintout::SetHtmlText}\label{wxhtmlprintoutsethtmltext} \membersection{wxHtmlPrintout::SetHtmlText}\label{wxhtmlprintoutsethtmltext}
\func{void}{SetHtmlText}{\param{const wxString\& }{html}, \param{const wxString\& }{basepath = wxEmptyString}, \param{bool }{isdir = TRUE}} \func{void}{SetHtmlText}{\param{const wxString\& }{html}, \param{const wxString\& }{basepath = wxEmptyString}, \param{bool }{isdir = TRUE}}
@@ -40,8 +35,6 @@ file). It is used to determine path for loading images, for example.}
\docparam{isdir}{FALSE if basepath is filename, TRUE if it is directory name \docparam{isdir}{FALSE if basepath is filename, TRUE if it is directory name
(see \helpref{wxFileSystem}{wxfilesystem} for detailed explanation)} (see \helpref{wxFileSystem}{wxfilesystem} for detailed explanation)}
\membersection{wxHtmlPrintout::SetHtmlFile}\label{wxhtmlprintoutsethtmlfile} \membersection{wxHtmlPrintout::SetHtmlFile}\label{wxhtmlprintoutsethtmlfile}
\func{void}{SetHtmlFile}{\param{const wxString\& }{htmlfile}} \func{void}{SetHtmlFile}{\param{const wxString\& }{htmlfile}}
@@ -49,8 +42,6 @@ file). It is used to determine path for loading images, for example.}
Prepare the class for printing this HTML {\bf file}. The file may be located on Prepare the class for printing this HTML {\bf file}. The file may be located on
any virtual file system or it may be normal file. any virtual file system or it may be normal file.
\membersection{wxHtmlPrintout::SetHeader}\label{wxhtmlprintoutsetheader} \membersection{wxHtmlPrintout::SetHeader}\label{wxhtmlprintoutsetheader}
\func{void}{SetHeader}{\param{const wxString\& }{header}, \param{int }{pg = wxPAGE\_ALL}} \func{void}{SetHeader}{\param{const wxString\& }{header}, \param{int }{pg = wxPAGE\_ALL}}
@@ -60,7 +51,8 @@ Sets page header.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{header}{HTML text to be used as header. You can use macros in it: \docparam{header}{HTML text to be used as header. You can use macros in it:
\begin{itemize}
\begin{itemize}\itemsep=0pt
\item @PAGENUM@ is replaced by page number \item @PAGENUM@ is replaced by page number
\item @PAGESCNT@ is replaced by total number of pages \item @PAGESCNT@ is replaced by total number of pages
\end{itemize} \end{itemize}
@@ -78,7 +70,8 @@ Sets page footer.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{footer}{HTML text to be used as footer. You can use macros in it: \docparam{footer}{HTML text to be used as footer. You can use macros in it:
\begin{itemize}
\begin{itemize}\itemsep=0pt
\item @PAGENUM@ is replaced by page number \item @PAGENUM@ is replaced by page number
\item @PAGESCNT@ is replaced by total number of pages \item @PAGESCNT@ is replaced by total number of pages
\end{itemize} \end{itemize}
@@ -86,7 +79,6 @@ Sets page footer.
\docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.} \docparam{pg}{one of wxPAGE\_ODD, wxPAGE\_EVEN and wxPAGE\_ALL constants.}
\membersection{wxHtmlPrintout::SetMargins}\label{wxhtmlprintoutsetmargins} \membersection{wxHtmlPrintout::SetMargins}\label{wxhtmlprintoutsetmargins}
\func{void}{SetMargins}{\param{float }{top = 25.2}, \param{float }{bottom = 25.2}, \param{float }{left = 25.2}, \param{float }{right = 25.2}, \param{float }{spaces = 5}} \func{void}{SetMargins}{\param{float }{top = 25.2}, \param{float }{bottom = 25.2}, \param{float }{left = 25.2}, \param{float }{right = 25.2}, \param{float }{spaces = 5}}

View File

@@ -5,7 +5,7 @@
\section{\class{wxHtmlTag}}\label{wxhtmltag} \section{\class{wxHtmlTag}}\label{wxhtmltag}
This class represents single HTML tag. This class represents a single HTML tag.
It is used by \helpref{tag handlers}{handlers}. It is used by \helpref{tag handlers}{handlers}.
\wxheading{Derived from} \wxheading{Derived from}
@@ -18,9 +18,9 @@ wxObject
\func{}{wxHtmlTag}{\param{const wxString\& }{source}, \param{int }{pos}, \param{int }{end\_pos}, \param{wxHtmlTagsCache* }{cache}} \func{}{wxHtmlTag}{\param{const wxString\& }{source}, \param{int }{pos}, \param{int }{end\_pos}, \param{wxHtmlTagsCache* }{cache}}
Constructor. You'll probably never have to construct wxHtmlTag object Constructor. You'll probably never have to construct a wxHtmlTag object
yourself. Feel free to ignore the constructor parameters... yourself. Feel free to ignore the constructor parameters.
(have a look at lib/htmlparser.cpp if you're interested in creating it) Have a look at lib/htmlparser.cpp if you're interested in creating it.
\membersection{wxHtmlTag::GetAllParams}\label{wxhtmltaggetallparams} \membersection{wxHtmlTag::GetAllParams}\label{wxhtmltaggetallparams}
@@ -145,25 +145,24 @@ Example : {\tt <FONT SIZE=+2 COLOR="\#FF00FF">} has two parameters named
Returns TRUE if this tag is ending one. Returns TRUE if this tag is ending one.
({\tt </FONT>} is ending tag, {\tt <FONT>} is not) ({\tt </FONT>} is ending tag, {\tt <FONT>} is not)
\membersection{wxHtmlTag::ScanParam}\label{wxhtmltagscanparam} \membersection{wxHtmlTag::ScanParam}\label{wxhtmltagscanparam}
\constfunc{wxString}{ScanParam}{\param{const wxString\& }{par}, \param{const char *}{format}, fuck} \constfunc{wxString}{ScanParam}{\param{const wxString\& }{par}, \param{const char *}{format}, fuck}
This method scans given parameter. Usage is exatly the same as sscanf's This method scans given parameter. Usage is exactly the same as sscanf's
usage except that you don't pass string but param name as the first parameter. usage except that you don't pass string but param name as the first parameter.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{par}{The name of tag you wanna query (in uppercase)} \docparam{par}{The name of tag you want to query (in uppercase)}
\docparam{format}{scanf()-like format string.} \docparam{format}{scanf()-like format string.}
\wxheading{Cygwin and Mingw32} \wxheading{Cygwin and Mingw32}
If you're using Cygwin beta 20 or Mingw32 compiler please remember If you're using Cygwin beta 20 or Mingw32 compiler please remember
that ScanParam() is only partially implemented!! The problem is that ScanParam() is only partially implemented! The problem is
that under Cygnus' GCC vsscanf() function is not implemented. I workarounded that under Cygnus' GCC vsscanf() function is not implemented. I worked around
this in a way which causes that you can use only one parameter in ... this in a way which causes that you can use only one parameter in ...
(and only one \% in {\it format}) (and only one \% in {\it format}).

View File

@@ -5,8 +5,8 @@
\section{\class{wxHtmlWidgetCell}}\label{wxhtmlwidgetcell} \section{\class{wxHtmlWidgetCell}}\label{wxhtmlwidgetcell}
wxHtmlWidgetCell is class that provides connection between HTML cell and widget (object derived wxHtmlWidgetCell is a class that provides a connection between HTML cells and widgets (an object derived
from wxWindow). You can use it to display things like forms, input boxes etc. in HTML window. from wxWindow). You can use it to display things like forms, input boxes etc. in an HTML window.
wxHtmlWidgetCell takes care of resizing and moving window. wxHtmlWidgetCell takes care of resizing and moving window.
@@ -20,7 +20,7 @@ wxHtmlWidgetCell takes care of resizing and moving window.
\func{}{wxHtmlWidgetCell}{\param{wxWindow* }{wnd}, \param{int }{w = 0}} \func{}{wxHtmlWidgetCell}{\param{wxWindow* }{wnd}, \param{int }{w = 0}}
Constructor Constructor.
\wxheading{Parameters} \wxheading{Parameters}

View File

@@ -7,13 +7,13 @@
wxHtmlWindow is probably the only class you will directly use wxHtmlWindow is probably the only class you will directly use
unless you want to do something special (like adding new tag unless you want to do something special (like adding new tag
handlers or MIME filters) handlers or MIME filters).
Purpose of this class is to display HTML page (either local The purpose of this class is to display HTML pages (either local
file or downloaded via HTTP protocol) in a window. Width file or downloaded via HTTP protocol) in a window. The width
of window is constant - given in constructor - virtual height of the window is constant - given in the constructor - and virtual height
is changed dynamicly depending on page size. is changed dynamically depending on page size.
Once the window is created you can set it's content by calling Once the window is created you can set its content by calling
\helpref{SetPage(text)}{wxhtmlwindowsetpage} or \helpref{SetPage(text)}{wxhtmlwindowsetpage} or
\helpref{LoadPage(filename)}{wxhtmlwindowloadpage}. \helpref{LoadPage(filename)}{wxhtmlwindowloadpage}.
@@ -33,13 +33,12 @@ Default constructor.
\func{}{wxHtmlWindow}{\param{wxWindow }{*parent}, \param{wxWindowID }{id = -1}, \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize}, \param{long }{style = wxHW_SCROLLBAR_AUTO}, \param{const wxString\& }{name = "htmlWindow"}} \func{}{wxHtmlWindow}{\param{wxWindow }{*parent}, \param{wxWindowID }{id = -1}, \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize}, \param{long }{style = wxHW_SCROLLBAR_AUTO}, \param{const wxString\& }{name = "htmlWindow"}}
Constructor. The parameters are same as in wxScrollWindow ctor. Constructor. The parameters are the same as for the \helpref{wxScrolledWindow}{wxscrolledwindow} constructor.
(Too lazy to document it once again... :-)
\wxheading{Parameters} \wxheading{Parameters}
\docparam{style}{wxHW\_SCROLLBAR\_NEVER, or wxHW\_SCROLLBAR\_AUTO. \docparam{style}{wxHW\_SCROLLBAR\_NEVER, or wxHW\_SCROLLBAR\_AUTO.
Affects appearance of vertical scrollbar in the window.} Affects the appearance of vertical scrollbar in the window.}
\membersection{wxHtmlWindow::AddFilter}\label{wxhtmlwindowaddfilter} \membersection{wxHtmlWindow::AddFilter}\label{wxhtmlwindowaddfilter}
@@ -48,7 +47,7 @@ Affects appearance of vertical scrollbar in the window.}
Adds \helpref{input filter}{filters} to the static list of available Adds \helpref{input filter}{filters} to the static list of available
filters. These filters are present by default: filters. These filters are present by default:
\begin{itemize} \begin{itemize}\itemsep=0pt
\item {\tt text/html} MIME type \item {\tt text/html} MIME type
\item {\tt image/*} MIME types \item {\tt image/*} MIME types
\item Plain Text filter (this filter is used if no other filter matches) \item Plain Text filter (this filter is used if no other filter matches)
@@ -133,7 +132,7 @@ Read values : all things set by SetFonts, SetBorders.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{cfg}{wxConfig from which you wanna read configuration} \docparam{cfg}{wxConfig from which you want to read the configuration.}
\docparam{path}{Optional path in config tree. If not given current path is used.} \docparam{path}{Optional path in config tree. If not given current path is used.}
@@ -157,20 +156,20 @@ This function sets font sizes and faces.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{normal_face}{This is face name for normal (i.e. non-fixed) font. \docparam{normal\_face}{This is face name for normal (i.e. non-fixed) font.
It can be either empty string (then the default face is choosen) or It can be either empty string (then the default face is choosen) or
platform-specific face name. Examples are "helvetica" under Unix or platform-specific face name. Examples are "helvetica" under Unix or
"Times New Roman" under Windows.} "Times New Roman" under Windows.}
\docparam{normal_italic_mode}{This is either wxSLANT or wxITALIC. \docparam{normal\_italic\_mode}{This is either wxSLANT or wxITALIC.
It determines how It determines how
italic (<I>..</I>) text is handled. See wxFont documentation for italic (<I>..</I>) text is handled. See wxFont documentation for
details. For example you should use wxSLANT in conjuction with details. For example you should use wxSLANT in conjuction with
"helvetica" face or wxITALIC with "times" face.} "helvetica" face or wxITALIC with "times" face.}
\docparam{fixed_face}{The same thing for fixed face ( <TT>..</TT> )} \docparam{fixed\_face}{The same thing for fixed face ( <TT>..</TT> )}
\docparam{fixed_italic_mode}{The same thing for fixed face.} \docparam{fixed\_italic\_mode}{The same thing for fixed face.}
\docparam{sizes}{This is an array of 7 items of {\it int} type. \docparam{sizes}{This is an array of 7 items of {\it int} type.
The values represent size of font with HTML size from -2 to +4 The values represent size of font with HTML size from -2 to +4
@@ -204,7 +203,7 @@ It will display the {\it source}. See example:
htmlwin -> SetPage("<html><body>Hello, world!</body></html>"); htmlwin -> SetPage("<html><body>Hello, world!</body></html>");
\end{verbatim} \end{verbatim}
If you want to load document from some location use If you want to load a document from some location use
\helpref{LoadPage}{wxhtmlwindowloadpage} instead. \helpref{LoadPage}{wxhtmlwindowloadpage} instead.
\wxheading{Parameters} \wxheading{Parameters}
@@ -213,13 +212,13 @@ If you want to load document from some location use
\wxheading{Return value} \wxheading{Return value}
FALSE if an error occured, TRUE otherwise FALSE if an error occured, TRUE otherwise.
\membersection{wxHtmlWindow::SetRelatedFrame}\label{wxhtmlwindowsetrelatedframe} \membersection{wxHtmlWindow::SetRelatedFrame}\label{wxhtmlwindowsetrelatedframe}
\func{void}{SetRelatedFrame}{\param{wxFrame* }{frame}, \param{const wxString\& }{format}} \func{void}{SetRelatedFrame}{\param{wxFrame* }{frame}, \param{const wxString\& }{format}}
Sets frame in which page title will be displayed. {\it format} is format of Sets the frame in which page title will be displayed. {\it format} is format of
frame title, e.g. "HtmlHelp : \%s". It must contain exactly one \%s. This frame title, e.g. "HtmlHelp : \%s". It must contain exactly one \%s. This
\%s is substituted with HTML page title. \%s is substituted with HTML page title.
@@ -241,15 +240,14 @@ this sets statusbar slot where messages will be displayed.
Saves custom settings into wxConfig. It uses the path 'path' Saves custom settings into wxConfig. It uses the path 'path'
if given, otherwise it saves info into currently selected path. if given, otherwise it saves info into currently selected path.
Regardless path is given or not the function creates sub-path Regardless of whether the path is given or not, the function creates sub-path
{\tt wxHtmlWindow} {\tt wxHtmlWindow}.
Saved values: all things set by SetFonts, SetBorders. Saved values: all things set by SetFonts, SetBorders.
\wxheading{Parameters} \wxheading{Parameters}
\docparam{cfg}{wxConfig to which you wanna save configuration} \docparam{cfg}{wxConfig to which you want to save the configuration.}
\docparam{path}{Optional path in config tree. If not given current path is used.}
\docparam{path}{Optional path in config tree. If not given, the current path is used.}

View File

@@ -85,8 +85,8 @@ Returns default horizontal alignment.
Returns (average) char height in standard font. It's used as DC-independent metrics. Returns (average) char height in standard font. It's used as DC-independent metrics.
{\bf Note:} This function doesn't return {\it actual} height. If you wanna {\bf Note:} This function doesn't return {\it actual} height. If you want to
know height of current font, call {\tt GetDC -> GetCharHeight()} know the height of the current font, call {\tt GetDC -> GetCharHeight()}.
\membersection{wxHtmlWinParser::GetCharWidth}\label{wxhtmlwinparsergetcharwidth} \membersection{wxHtmlWinParser::GetCharWidth}\label{wxhtmlwinparsergetcharwidth}
@@ -94,8 +94,8 @@ know height of current font, call {\tt GetDC -> GetCharHeight()}
Returns average char width in standard font. It's used as DC-independent metrics. Returns average char width in standard font. It's used as DC-independent metrics.
{\bf Note:} This function doesn't return {\it actual} width. If you wanna {\bf Note:} This function doesn't return {\it actual} width. If you want to
know height of current font, call {\tt GetDC -> GetCharWidth()} know the height of the current font, call {\tt GetDC -> GetCharWidth()}
\membersection{wxHtmlWinParser::GetContainer}\label{wxhtmlwinparsergetcontainer} \membersection{wxHtmlWinParser::GetContainer}\label{wxhtmlwinparsergetcontainer}

View File

@@ -85,7 +85,7 @@
\setfooter{\thepage}{}{}{}{}{\thepage}% \setfooter{\thepage}{}{}{}{}{\thepage}%
\begin{center} \begin{center}
Copyright \copyright{} 1998 Julian Smart, Robert Roebling and other Copyright \copyright{} 1999 Julian Smart, Robert Roebling, Vadim Zeitlin and other
members of the wxWindows team\\ members of the wxWindows team\\
Portions \copyright{} 1996 Artificial Intelligence Applications Institute\\ Portions \copyright{} 1996 Artificial Intelligence Applications Institute\\
\end{center} \end{center}

View File

@@ -75,8 +75,8 @@ no data in (any of) the supported format(s) is available. If it returns {\tt
TRUE}, the data has been successfully transfered to wxDataObject. TRUE}, the data has been successfully transfered to wxDataObject.
{\bf TODO} document drag and drop side when the API is finalised {\bf TODO} document drag and drop side when the API is finalised
% !!!!!!!!!!!!!!!!!!!!!!!!!!!!! % !!!!!!!!!!!!!!!!!!!!!!!!!!!!!
% Vadim, please remember the new line at the end of each file. Please % Vadim, please remember the new line at the end of each file. Please
% also remember to compile the .hlp file to check for bad references etc., % also remember to compile the .hlp file to check for bad references etc.,
% before checking in. I have removed references that were unresolved. - JACS % before checking in. I have removed references that were unresolved. - JACS

View File

@@ -54,7 +54,9 @@ public:
* wxSashWindow flags * wxSashWindow flags
*/ */
#define wxSW_3D 0x0004 #define wxSW_NOBORDER 0x0000
#define wxSW_3D 0x0010
#define wxSW_BORDER 0x0020
/* /*
* wxSashWindow allows any of its edges to have a sash which can be dragged * wxSashWindow allows any of its edges to have a sash which can be dragged

View File

@@ -92,8 +92,9 @@
#define wxUSE_SPINBTN 1 #define wxUSE_SPINBTN 1
// Define 1 to compile spin button // Define 1 to compile spin button
// use wxStaticLine class (separator line in the dialog)?
#define wxUSE_STATLINE 1 #define wxUSE_STATLINE 1
// use wxStaticLine class
#define wxUSE_CHECKLISTBOX 1 #define wxUSE_CHECKLISTBOX 1
// Define 1 to compile check listbox // Define 1 to compile check listbox
@@ -118,14 +119,8 @@
#define wxUSE_WX_RESOURCES 1 #define wxUSE_WX_RESOURCES 1
// Use .wxr resource mechanism (requires PrologIO library) // Use .wxr resource mechanism (requires PrologIO library)
// support for startup tips (wxShowTip &c)
#define wxUSE_STARTUP_TIPS 1 #define wxUSE_STARTUP_TIPS 1
// support for startup tips (wxShowTip &c)
// BC++/Win16 can't cope with the amount of data in resource.cpp
#if defined(__WIN16__) && defined(__BORLANDC__)
#undef wxUSE_WX_RESOURCES
#define wxUSE_WX_RESOURCES 0
#endif
#define wxUSE_DOC_VIEW_ARCHITECTURE 1 #define wxUSE_DOC_VIEW_ARCHITECTURE 1
// Set to 0 to disable document/view architecture // Set to 0 to disable document/view architecture
@@ -396,6 +391,12 @@
#define wxUSE_ODBC 0 #define wxUSE_ODBC 0
#endif #endif
// BC++/Win16 can't cope with the amount of data in resource.cpp
#if defined(__WIN16__) && defined(__BORLANDC__)
#undef wxUSE_WX_RESOURCES
#define wxUSE_WX_RESOURCES 0
#endif
#if defined(__WXMSW__) && defined(__WATCOMC__) #if defined(__WXMSW__) && defined(__WATCOMC__)
#undef wxUSE_LIBJPEG #undef wxUSE_LIBJPEG
#define wxUSE_LIBJPEG 0 #define wxUSE_LIBJPEG 0

View File

@@ -163,7 +163,7 @@ bool MyApp::OnInit(void)
MyFrame::MyFrame(wxFrame *frame, const wxString& title, const wxPoint& pos, const wxSize& size): MyFrame::MyFrame(wxFrame *frame, const wxString& title, const wxPoint& pos, const wxSize& size):
wxFrame(frame, -1, title, pos, size) wxFrame(frame, -1, title, pos, size)
{ {
grid = (wxGenericGrid *) NULL; grid = (wxGrid*) NULL;
} }
BEGIN_EVENT_TABLE(MyFrame, wxFrame) BEGIN_EVENT_TABLE(MyFrame, wxFrame)

View File

@@ -402,7 +402,7 @@ void wxSashWindow::DrawBorders(wxDC& dc)
wxPen lightShadowPen(m_lightShadowColour, 1, wxSOLID); wxPen lightShadowPen(m_lightShadowColour, 1, wxSOLID);
wxPen hilightPen(m_hilightColour, 1, wxSOLID); wxPen hilightPen(m_hilightColour, 1, wxSOLID);
if ( GetWindowStyleFlag() & wxSP_3D ) if ( GetWindowStyleFlag() & wxSW_3D )
{ {
dc.SetPen(mediumShadowPen); dc.SetPen(mediumShadowPen);
dc.DrawLine(0, 0, w-1, 0); dc.DrawLine(0, 0, w-1, 0);
@@ -421,7 +421,7 @@ void wxSashWindow::DrawBorders(wxDC& dc)
dc.DrawLine(w-2, 1, w-2, h-2); // Right hand side dc.DrawLine(w-2, 1, w-2, h-2); // Right hand side
dc.DrawLine(1, h-2, w-1, h-2); // Bottom dc.DrawLine(1, h-2, w-1, h-2); // Bottom
} }
else if ( GetWindowStyleFlag() & wxSP_BORDER ) else if ( GetWindowStyleFlag() & wxSW_BORDER )
{ {
dc.SetBrush(*wxTRANSPARENT_BRUSH); dc.SetBrush(*wxTRANSPARENT_BRUSH);
dc.SetPen(*wxBLACK_PEN); dc.SetPen(*wxBLACK_PEN);

View File

@@ -11,7 +11,7 @@
* WriteDIB() - Writes a global handle in CF_DIB format* * WriteDIB() - Writes a global handle in CF_DIB format*
* to a file. * * to a file. *
* * * *
* PaletteSize() - Calculates the palette size in bytes * * wxPaletteSize() - Calculates the palette size in bytes *
* of given DIB * * of given DIB *
* * * *
* DibNumColors() - Determines the number of colors in DIB * * DibNumColors() - Determines the number of colors in DIB *
@@ -87,7 +87,7 @@ static DWORD PASCAL lread(int fh, VOID FAR *pv, DWORD ul);
static DWORD PASCAL lwrite(int fh, VOID FAR *pv, DWORD ul); static DWORD PASCAL lwrite(int fh, VOID FAR *pv, DWORD ul);
static BOOL WriteDIB (LPTSTR szFile,HANDLE hdib); static BOOL WriteDIB (LPTSTR szFile,HANDLE hdib);
static WORD PaletteSize (VOID FAR * pv); WORD wxPaletteSize (VOID FAR * pv); // This is non-static as some apps use it externally
static WORD DibNumColors (VOID FAR * pv); static WORD DibNumColors (VOID FAR * pv);
// HANDLE DibFromBitmap (HBITMAP hbm, DWORD biStyle, WORD biBits, HPALETTE hpal); // HANDLE DibFromBitmap (HBITMAP hbm, DWORD biStyle, WORD biBits, HPALETTE hpal);
static BOOL PASCAL MakeBitmapAndPalette(HDC,HANDLE,HPALETTE *,HBITMAP *); static BOOL PASCAL MakeBitmapAndPalette(HDC,HANDLE,HPALETTE *,HBITMAP *);
@@ -128,7 +128,7 @@ static BOOL WriteDIB(LPTSTR szFile, HANDLE hdib)
hdr.bfReserved1 = 0; hdr.bfReserved1 = 0;
hdr.bfReserved2 = 0; hdr.bfReserved2 = 0;
hdr.bfOffBits = (DWORD) sizeof(BITMAPFILEHEADER) + lpbi->biSize + hdr.bfOffBits = (DWORD) sizeof(BITMAPFILEHEADER) + lpbi->biSize +
PaletteSize(lpbi); wxPaletteSize(lpbi);
/* Write the file header */ /* Write the file header */
_lwrite(fh, (LPSTR) &hdr, sizeof(BITMAPFILEHEADER)); _lwrite(fh, (LPSTR) &hdr, sizeof(BITMAPFILEHEADER));
@@ -143,7 +143,7 @@ static BOOL WriteDIB(LPTSTR szFile, HANDLE hdib)
/**************************************************************************** /****************************************************************************
* * * *
* FUNCTION : PaletteSize(VOID FAR * pv) * * FUNCTION : wxPaletteSize(VOID FAR * pv) *
* * * *
* PURPOSE : Calculates the palette size in bytes. If the info. block * * PURPOSE : Calculates the palette size in bytes. If the info. block *
* is of the BITMAPCOREHEADER type, the number of colors is * * is of the BITMAPCOREHEADER type, the number of colors is *
@@ -154,7 +154,7 @@ static BOOL WriteDIB(LPTSTR szFile, HANDLE hdib)
* * * *
****************************************************************************/ ****************************************************************************/
static WORD PaletteSize(VOID FAR * pv) WORD wxPaletteSize(VOID FAR * pv)
{ {
LPBITMAPINFOHEADER lpbi; LPBITMAPINFOHEADER lpbi;
WORD NumColors; WORD NumColors;
@@ -259,7 +259,7 @@ static HANDLE DibFromBitmap(HBITMAP hbm, DWORD biStyle, WORD biBits, HPALETTE hp
bi.biClrUsed = 0; bi.biClrUsed = 0;
bi.biClrImportant = 0; bi.biClrImportant = 0;
dwLen = bi.biSize + PaletteSize(&bi); dwLen = bi.biSize + wxPaletteSize(&bi);
hdc = GetDC((HWND) NULL); hdc = GetDC((HWND) NULL);
hpal = SelectPalette(hdc, hpal, FALSE); hpal = SelectPalette(hdc, hpal, FALSE);
@@ -299,7 +299,7 @@ static HANDLE DibFromBitmap(HBITMAP hbm, DWORD biStyle, WORD biBits, HPALETTE hp
} }
/* realloc the buffer big enough to hold all the bits */ /* realloc the buffer big enough to hold all the bits */
dwLen = bi.biSize + PaletteSize(&bi) + bi.biSizeImage; dwLen = bi.biSize + wxPaletteSize(&bi) + bi.biSizeImage;
if (h = GlobalReAlloc(hdib, dwLen, 0)) if (h = GlobalReAlloc(hdib, dwLen, 0))
hdib = h; hdib = h;
else { else {
@@ -324,7 +324,7 @@ static HANDLE DibFromBitmap(HBITMAP hbm, DWORD biStyle, WORD biBits, HPALETTE hp
hbm, hbm,
0, 0,
(WORD) bi.biHeight, (WORD) bi.biHeight,
(LPSTR) lpbi + (WORD) lpbi->biSize + PaletteSize(lpbi), (LPSTR) lpbi + (WORD) lpbi->biSize + wxPaletteSize(lpbi),
(LPBITMAPINFO) lpbi, DIB_RGB_COLORS) == 0) { (LPBITMAPINFO) lpbi, DIB_RGB_COLORS) == 0) {
GlobalUnlock(hdib); GlobalUnlock(hdib);
hdib = NULL; hdib = NULL;
@@ -815,7 +815,7 @@ static void InitBitmapInfoHeader (LPBITMAPINFOHEADER lpBmInfoHdr,
LPSTR wxFindDIBBits (LPSTR lpbi) LPSTR wxFindDIBBits (LPSTR lpbi)
{ {
return (lpbi + *(LPDWORD)lpbi + PaletteSize (lpbi)); return (lpbi + *(LPDWORD)lpbi + wxPaletteSize (lpbi));
} }
//--------------------------------------------------------------------- //---------------------------------------------------------------------
@@ -868,7 +868,7 @@ HANDLE wxBitmapToDIB (HBITMAP hBitmap, HPALETTE hPal)
// into this memory, and find out where the bitmap bits go. // into this memory, and find out where the bitmap bits go.
hDIB = GlobalAlloc (GHND, sizeof (BITMAPINFOHEADER) + hDIB = GlobalAlloc (GHND, sizeof (BITMAPINFOHEADER) +
PaletteSize ((LPSTR) &bmInfoHdr) + bmInfoHdr.biSizeImage); wxPaletteSize ((LPSTR) &bmInfoHdr) + bmInfoHdr.biSizeImage);
if (!hDIB) if (!hDIB)
return NULL; return NULL;

View File

@@ -216,6 +216,7 @@ void MyApp::GenerateSamples(const wxString& dir)
0)); 0));
GenerateSample("FractalVC", "fractal", dir + wxString("/samples/fractal"), wxStringList("fractal.cpp", 0)); GenerateSample("FractalVC", "fractal", dir + wxString("/samples/fractal"), wxStringList("fractal.cpp", 0));
GenerateSample("GridVC", "test", dir + wxString("/samples/grid"), wxStringList("test.cpp", 0)); GenerateSample("GridVC", "test", dir + wxString("/samples/grid"), wxStringList("test.cpp", 0));
GenerateSample("NewGridVC", "griddemo", dir + wxString("/samples/newgrid"), wxStringList("griddemo.cpp", 0));
GenerateSample("HelpVC", "demo", dir + wxString("/samples/help"), wxStringList("demo.cpp", 0)); GenerateSample("HelpVC", "demo", dir + wxString("/samples/help"), wxStringList("demo.cpp", 0));
// wxHTML samples // wxHTML samples