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)
|
2001-06-26 16:59:19 -04:00
|
|
|
// Licence: wxWindows license
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#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; }
|
|
|
|
|
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_
|