]> git.saurik.com Git - wxWidgets.git/blame - include/wx/palmos/statusbr.h
applied heavily modified patch 1116702: support for specifying disabled toolbar image...
[wxWidgets.git] / include / wx / palmos / statusbr.h
CommitLineData
ffecfa5a 1///////////////////////////////////////////////////////////////////////////////
e1d63b79 2// Name: wx/palmos/statusbr.h
ffecfa5a 3// Purpose: Palm OS implementation of wxStatusBar
e1d63b79 4// Author: William Osborne - minimal working wxPalmOS port
ffecfa5a
JS
5// Modified by:
6// Created: 10/13/04
e1d63b79 7// RCS-ID: $Id$
ffecfa5a
JS
8// Copyright: (c) William Osborne
9// Licence: wxWindows licence
10///////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_STATUSBR_H_
13#define _WX_STATUSBR_H_
14
15#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
16#pragma interface "statusbr.h"
17#endif
18
19#if wxUSE_NATIVE_STATUSBAR
20
21class WXDLLEXPORT wxStatusBarPalm : public wxStatusBarBase
22{
23public:
24 // ctors and such
25 wxStatusBarPalm();
26 wxStatusBarPalm(wxWindow *parent,
b08cd3bf
WS
27 wxWindowID id = wxID_ANY,
28 long style = wxST_SIZEGRIP,
29 const wxString& name = wxEmptyString)
ffecfa5a
JS
30 {
31 (void)Create(parent, id, style, name);
32 }
33
34 bool Create(wxWindow *parent,
b08cd3bf 35 wxWindowID id = wxID_ANY,
ffecfa5a
JS
36 long style = wxST_SIZEGRIP,
37 const wxString& name = wxEmptyString);
38
39 virtual ~wxStatusBarPalm();
40
b08cd3bf
WS
41 // for native status bar use native check for visibility
42 virtual bool IsShown() const;
43 virtual bool Show( bool show = true );
44
ffecfa5a
JS
45 // a status line can have several (<256) fields numbered from 0
46 virtual void SetFieldsCount(int number = 1, const int *widths = NULL);
47
48 // each field of status line has it's own text
49 virtual void SetStatusText(const wxString& text, int number = 0);
50 virtual wxString GetStatusText(int number = 0) const;
51
52 // set status line fields' widths
53 virtual void SetStatusWidths(int n, const int widths_field[]);
54
55 // sets the minimal vertical size of the status bar
56 virtual void SetMinHeight(int height);
57
58 // get the position and size of the field's internal bounding rectangle
59 virtual bool GetFieldRect(int i, wxRect& rect) const;
60
61 // get the border size
62 virtual int GetBorderX() const;
63 virtual int GetBorderY() const;
e1d63b79 64
ffecfa5a
JS
65 void DrawStatusBar();
66
67protected:
68 void CopyFieldsWidth(const int widths[]);
69 void SetFieldsWidth();
70
71 // store the text in the status bar
72 wxListString **StatusTextBuffer;
73 void SetStatusBufferText(const wxString& text, int number);
74 wxString GetStatusBufferText(int number);
75 wxListString *GetOrCreateStatusBuffer(int i);
76 wxListString *GetStatusBufferStack(int i) const;
e1d63b79 77 void DeleteStatusBuffer();
ffecfa5a
JS
78
79 // override base class virtual
80 void DoMoveWindow(int x, int y, int width, int height);
81
82private:
83 DECLARE_DYNAMIC_CLASS_NO_COPY(wxStatusBarPalm)
84};
85
86#endif // wxUSE_NATIVE_STATUSBAR
87
88#endif