1. wxStaticText, wxStaticBox, wxButton drawing implemented
2. "pseudo dynamic" wxTheme creation 3. hack to solve GetBestSize() problem 4. more methods in wxDC:: GetMultiLineTextExtent(), DrawLabel() git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/wxUNIVERSAL@8107 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
73
include/wx/univ/button.h
Normal file
73
include/wx/univ/button.h
Normal file
@@ -0,0 +1,73 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/univ/button.h
|
||||
// Purpose: wxButton for wxUniversal
|
||||
// Author: Vadim Zeitlin
|
||||
// Modified by:
|
||||
// Created: 15.08.00
|
||||
// RCS-ID: $Id$
|
||||
// Copyright: (c) 2000 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
|
||||
// Licence: wxWindows license
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_UNIV_BUTTON_H_
|
||||
#define _WX_UNIV_BUTTON_H_
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma interface "univbutton.h"
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Pushbutton
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class WXDLLEXPORT wxButton : public wxButtonBase
|
||||
{
|
||||
public:
|
||||
wxButton() { Init(); }
|
||||
wxButton(wxWindow *parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxButtonNameStr)
|
||||
{
|
||||
Init();
|
||||
|
||||
Create(parent, id, label, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
bool Create(wxWindow *parent,
|
||||
wxWindowID id,
|
||||
const wxString& label,
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = 0,
|
||||
const wxValidator& validator = wxDefaultValidator,
|
||||
const wxString& name = wxButtonNameStr);
|
||||
|
||||
virtual ~wxButton();
|
||||
|
||||
virtual void SetDefault();
|
||||
|
||||
virtual bool IsPressed() const { return m_isPressed; }
|
||||
virtual bool IsDefault() const { return m_isDefault; }
|
||||
|
||||
protected:
|
||||
virtual wxSize DoGetBestSize() const;
|
||||
virtual void DoDraw(wxControlRenderer *renderer);
|
||||
|
||||
// common part of all ctors
|
||||
void Init();
|
||||
|
||||
bool m_isPressed,
|
||||
m_isDefault;
|
||||
|
||||
private:
|
||||
DECLARE_DYNAMIC_CLASS(wxButton)
|
||||
};
|
||||
|
||||
#endif
|
||||
// _WX_BUTTON_H_
|
||||
|
Reference in New Issue
Block a user