2001-06-26 16:59:19 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: wx/univ/stattext.h
|
|
|
|
// Purpose: wxStaticText
|
|
|
|
// Author: Vadim Zeitlin
|
|
|
|
// Modified by:
|
|
|
|
// Created: 14.08.00
|
|
|
|
// RCS-ID: $Id$
|
2001-07-02 15:42:27 -04:00
|
|
|
// Copyright: (c) 2000 SciTech Software, Inc. (www.scitechsoft.com)
|
2003-03-17 05:34:04 -05:00
|
|
|
// Licence: wxWindows licence
|
2001-06-26 16:59:19 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _WX_UNIV_STATTEXT_H_
|
|
|
|
#define _WX_UNIV_STATTEXT_H_
|
|
|
|
|
|
|
|
#ifdef __GNUG__
|
2001-07-04 14:07:15 -04:00
|
|
|
#pragma interface "univstattext.h"
|
2001-06-26 16:59:19 -04:00
|
|
|
#endif
|
|
|
|
|
|
|
|
class WXDLLEXPORT wxStaticText : public wxStaticTextBase
|
|
|
|
{
|
|
|
|
public:
|
2002-02-10 14:07:40 -05:00
|
|
|
wxStaticText() { }
|
|
|
|
|
2001-06-26 16:59:19 -04:00
|
|
|
// usual ctor
|
|
|
|
wxStaticText(wxWindow *parent,
|
|
|
|
const wxString& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
const wxSize& size = wxDefaultSize)
|
|
|
|
{
|
|
|
|
Create(parent, -1, label, pos, size, 0, wxStaticTextNameStr);
|
|
|
|
}
|
|
|
|
|
|
|
|
// full form
|
|
|
|
wxStaticText(wxWindow *parent,
|
|
|
|
wxWindowID id,
|
|
|
|
const wxString& label,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
2001-07-03 15:38:19 -04:00
|
|
|
const wxSize& size = wxDefaultSize,
|
2001-06-26 16:59:19 -04:00
|
|
|
long style = 0,
|
|
|
|
const wxString &name = wxStaticTextNameStr)
|
|
|
|
{
|
|
|
|
Create(parent, id, label, pos, size, style, name);
|
|
|
|
}
|
|
|
|
|
|
|
|
// function ctor
|
|
|
|
bool Create(wxWindow *parent,
|
|
|
|
wxWindowID id,
|
|
|
|
const wxString &label,
|
|
|
|
const wxPoint &pos = wxDefaultPosition,
|
2001-07-03 15:38:19 -04:00
|
|
|
const wxSize &size = wxDefaultSize,
|
2001-06-26 16:59:19 -04:00
|
|
|
long style = 0,
|
|
|
|
const wxString &name = wxStaticTextNameStr);
|
|
|
|
|
|
|
|
// implementation only from now on
|
|
|
|
|
|
|
|
virtual void SetLabel(const wxString& label);
|
|
|
|
|
2002-04-14 10:42:43 -04:00
|
|
|
virtual bool HasTransparentBackground() { return TRUE; }
|
2003-02-18 04:40:30 -05:00
|
|
|
|
|
|
|
virtual bool IsFocused() const { return FALSE; }
|
|
|
|
|
2001-06-26 16:59:19 -04:00
|
|
|
protected:
|
|
|
|
// calculate the optimal size for the label
|
|
|
|
virtual wxSize DoGetBestClientSize() const;
|
|
|
|
|
|
|
|
// draw the control
|
|
|
|
virtual void DoDraw(wxControlRenderer *renderer);
|
2001-07-03 15:38:19 -04:00
|
|
|
|
|
|
|
DECLARE_ABSTRACT_CLASS(wxStaticText)
|
2001-06-26 16:59:19 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // _WX_UNIV_STATTEXT_H_
|