X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fcharwindow.h;h=cabd343bd9ed8f6589713f7e0bdc6150ed9022f8;hb=faaae13292af283e277b0d1480aad54a6e4a2dd6;hp=19fefb2e31ff4e448e9644284d701b717e4e63e9;hpb=4e11c12e60477f13a26c0bbad41fbd9a2b1db5d9;p=ttedit diff --git a/src/charwindow.h b/src/charwindow.h index 19fefb2..cabd343 100755 --- a/src/charwindow.h +++ b/src/charwindow.h @@ -1,33 +1,56 @@ -// -// CHARWINDOW.H: Header file -// -// by James L. Hammons -// (C) 2008 Underground Software -// - -#ifndef __CHARWINDOW_H__ -#define __CHARWINDOW_H__ - -#include // So that whoever uses this can without having - // to pull in a bunch of references manually -#include - -class CharWindow: public wxMiniFrame -{ - private: - protected: - public: - wxBitmap * bmp; - - // Constructor and destructor -// CharWindow(wxFrame * parent, const wxPoint &pos = wxDefaultPosition, const wxSize &size = wxDefaultSize, long style = 0); - CharWindow(wxFrame * parent, const wxString &title, const wxPoint &pos, const wxSize &size, long style); - ~CharWindow(void); - - void OnPaint(wxPaintEvent &e); -// void OnMouseEvent(wxMouseEvent &e); - - DECLARE_EVENT_TABLE() -}; - -#endif // __CHARWINDOW_H__ +// +// CHARWINDOW.H: Header file +// +// by James L. Hammons +// (C) 2009 Underground Software +// + +#ifndef __CHARWINDOW_H__ +#define __CHARWINDOW_H__ + +#include +#include "glyphpoints.h" + +class CharWindow: public QWidget +{ + Q_OBJECT + + public: + CharWindow(QWidget * parent = NULL); + void MakePathFromPoints(GlyphPoints * gp); + + protected: + QSize minimumSizeHint() const; + QSize sizeHint() const; + void paintEvent(QPaintEvent * event); + + private: + QImage img; + QPainterPath * path; +}; + +#if 0 +#include // So that whoever uses this can without having + // to pull in a bunch of references manually +#include + +class CharWindow: public wxMiniFrame +{ + private: + protected: + public: + wxBitmap * bmp; + + // Constructor and destructor +// CharWindow(wxFrame * parent, const wxPoint &pos = wxDefaultPosition, const wxSize &size = wxDefaultSize, long style = 0); + CharWindow(wxFrame * parent, const wxString &title, const wxPoint &pos, const wxSize &size, long style); + ~CharWindow(void); + + void OnPaint(wxPaintEvent &e); +// void OnMouseEvent(wxMouseEvent &e); + + DECLARE_EVENT_TABLE() +}; +#endif + +#endif // __CHARWINDOW_H__