]> git.saurik.com Git - wxWidgets.git/blame - include/wx/msw/combobox.h
added Show/HideNativeCaret() (patch 759924)
[wxWidgets.git] / include / wx / msw / combobox.h
CommitLineData
2bda0e17 1/////////////////////////////////////////////////////////////////////////////
f6bcfd97 2// Name: wx/msw/combobox.h
2bda0e17
KB
3// Purpose: wxComboBox class
4// Author: Julian Smart
5// Modified by:
6// Created: 01/02/97
7// RCS-ID: $Id$
bbcdf8bc 8// Copyright: (c) Julian Smart
4438caf4 9// Licence: wxWindows licence
2bda0e17
KB
10/////////////////////////////////////////////////////////////////////////////
11
bbcdf8bc
JS
12#ifndef _WX_COMBOBOX_H_
13#define _WX_COMBOBOX_H_
2bda0e17
KB
14
15#ifdef __GNUG__
4438caf4 16 #pragma interface "combobox.h"
2bda0e17
KB
17#endif
18
19#include "wx/choice.h"
20
47d67540 21#if wxUSE_COMBOBOX
2bda0e17 22
4438caf4
VZ
23// ----------------------------------------------------------------------------
24// Combobox control
25// ----------------------------------------------------------------------------
26
2bda0e17
KB
27class WXDLLEXPORT wxComboBox: public wxChoice
28{
4438caf4
VZ
29 DECLARE_DYNAMIC_CLASS(wxComboBox)
30
31public:
32 wxComboBox() { }
33
34 wxComboBox(wxWindow *parent, wxWindowID id,
35 const wxString& value = wxEmptyString,
36 const wxPoint& pos = wxDefaultPosition,
37 const wxSize& size = wxDefaultSize,
38 int n = 0, const wxString choices[] = NULL,
39 long style = 0,
40 const wxValidator& validator = wxDefaultValidator,
41 const wxString& name = wxComboBoxNameStr)
42 {
43 Create(parent, id, value, pos, size, n, choices, style, validator, name);
44 }
45
f6bcfd97
BP
46 bool Create(wxWindow *parent,
47 wxWindowID id,
48 const wxString& value = wxEmptyString,
49 const wxPoint& pos = wxDefaultPosition,
50 const wxSize& size = wxDefaultSize,
51 int n = 0,
52 const wxString choices[] = NULL,
53 long style = 0,
54 const wxValidator& validator = wxDefaultValidator,
55 const wxString& name = wxComboBoxNameStr);
4438caf4
VZ
56
57 // List functions: see wxChoice
58
59 // Text field functions
60 wxString GetValue() const { return GetLabel(); }
61 virtual void SetValue(const wxString& value);
62
63 // Clipboard operations
64 virtual void Copy();
65 virtual void Cut();
66 virtual void Paste();
67 virtual void SetInsertionPoint(long pos);
68 virtual void SetInsertionPointEnd();
69 virtual long GetInsertionPoint() const;
70 virtual long GetLastPosition() const;
71 virtual void Replace(long from, long to, const wxString& value);
72 virtual void Remove(long from, long to);
73 virtual void SetSelection(int n) { wxChoice::SetSelection(n); }
74 virtual void SetSelection(long from, long to);
75 virtual void SetEditable(bool editable);
76
f6bcfd97 77 // implementation only from now on
4438caf4 78 virtual bool MSWCommand(WXUINT param, WXWORD id);
f6bcfd97
BP
79 bool MSWProcessEditMsg(WXUINT msg, WXWPARAM wParam, WXLPARAM lParam);
80 virtual WXHBRUSH OnCtlColor(WXHDC pDC, WXHWND pWnd, WXUINT nCtlColor,
81 WXUINT message, WXWPARAM wParam, WXLPARAM lParam);
82
83 WXHWND GetEditHWND() const;
2bda0e17
KB
84};
85
47d67540 86#endif // wxUSE_COMBOBOX
2bda0e17 87#endif
bbcdf8bc 88 // _WX_COMBOBOX_H_