]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/delgrend.tex
set initial GTK_CAN_FOCUS value to match AcceptsFocus (fixes wxTreeCtrl text control...
[wxWidgets.git] / docs / latex / wx / delgrend.tex
1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2 %% Name: delgrend.tex
3 %% Purpose: wxDelegateRendererNative documentation
4 %% Author: Vadim Zeitlin
5 %% Modified by:
6 %% Created: 11.08.03
7 %% RCS-ID: $Id$
8 %% Copyright: (c) 2003 Vadim Zeitlin <vadim@wxwindows.org>
9 %% License: wxWindows license
10 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11
12 \section{\class{wxDelegateRendererNative}}\label{wxdelegaterenderernative}
13
14 wxDelegateRendererNative allows reuse of renderers code by forwarding all the
15 \helpref{wxRendererNative}{wxrenderernative} methods to the given object and
16 thus allowing you to only modify some of its methods -- without having to
17 reimplement all of them.
18
19 Note that the ``normal'', inheritance-based approach, doesn't work with the
20 renderers as it is impossible to derive from a class unknown at compile-time
21 and the renderer is only chosen at run-time. So suppose that you want to only
22 add something to the drawing of the tree control buttons but leave all the
23 other methods unchanged -- the only way to do it, considering that the renderer
24 class which you want to customize might not even be written yet when you write
25 your code (it could be written later and loaded from a DLL during run-time), is
26 by using this class.
27
28 Except for the constructor, it has exactly the same methods as
29 \helpref{wxRendererNative}{wxrenderernative} and their implementation is
30 trivial: they are simply forwarded to the real renderer. Note that the ``real''
31 renderer may, in turn, be a wxDelegateRendererNative as well and that there may
32 be arbitrarily many levels like this -- but at the end of the chain there must
33 be a real renderer which does the drawing.
34
35 \wxheading{Derived from}
36
37 \helpref{wxRendererNative}{wxrenderernative}
38
39 \wxheading{Include files}
40
41 <wx/renderer.h>
42
43 \wxheading{Library}
44
45 \helpref{wxCore}{librarieslist}
46
47
48 \latexignore{\rtfignore{\wxheading{Members}}}
49
50 \membersection{wxDelegateRendererNative::wxDelegateRendererNative}\label{wxdelegaterenderernativector}
51
52 \func{}{wxDelegateRendererNative}{\void}
53
54 \func{}{wxDelegateRendererNative}{\param{wxRendererNative\& }{rendererNative}}
55
56 The default constructor does the same thing as the other one except that it
57 uses the \helpref{generic renderer}{wxrenderernativegetgeneric} instead of the
58 user-specified \arg{rendererNative}.
59
60 In any case, this sets up the delegate renderer object to follow all calls to
61 the specified real renderer.
62
63 Note that this object does \emph{not} take ownership of (i.e. won't delete)
64 \arg{rendererNative}.
65
66
67 \membersection{wxDelegateRendererNative::DrawXXX}\label{wxdelegaterenderernativedrawxxx}
68
69 \func{}{DrawXXX}{\param{}{$\ldots$}}
70
71 This class also provides all the virtual methods of
72 \helpref{wxRendererNative}{wxrenderernative}, please refer to that class
73 documentation for the details.
74