4 License: GNU General Public License (GPL) version 2
5 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt)
9 This file is part of wxKanjiPad, a port of KanjiPad to wxWidgets with
10 some minor additional modifications. It uses and is based off the
11 modified kanjipad source code used in im-ja (http://im-ja.sourceforge.net/).
13 This program is free software; you can redistribute it and/or modify
14 it under the terms of the GNU General Public License as published by
15 the Free Software Foundation; either version 2 of the License, or
16 (at your option) any later version.
18 This program is distributed in the hope that it will be useful,
19 but WITHOUT ANY WARRANTY; without even the implied warranty of
20 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 GNU General Public License for more details.
23 You should have received a copy of the GNU General Public License along
24 with this program; if not, write to the Free Software Foundation, Inc.,
25 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
28 #ifndef panel_kanjipad_h
29 #define panel_kanjipad_h
31 /* Stock wxWidgets includes */
32 #include "wx/wxprec.h"
40 #include "wx/process.h"
44 #define KANJIPAD_MAX_KANJI 5
46 class PanelKanjiPad
: public wxPanel
{
48 PanelKanjiPad(wxWindow
*owner
, wxWindowID id
=wxID_ANY
,
49 const wxPoint
& pos
=wxDefaultPosition
,
50 const wxSize
& size
=wxDefaultSize
,
51 long style
=wxBORDER_SIMPLE
,
52 const wxString
& name
= _T("panelkanjipad"));
55 list
< list
<wxPoint
> > const* GetStrokes();
58 void OnMouseDown(wxMouseEvent
& ev
);
59 void OnMouseUp(wxMouseEvent
& ev
);
60 void OnMouseMove(wxMouseEvent
& ev
);
61 void OnMouseRightDown(wxMouseEvent
& ev
);
62 void OnPaint(wxPaintEvent
& ev
);
63 void AfterEngineCall(wxProcessEvent
& ev
);
65 wxChar results
[KANJIPAD_MAX_KANJI
];
68 list
<wxPoint
> currentStroke
;
69 list
< list
<wxPoint
> > strokes
;
71 /* Related to running kpengine process */
73 wxInputStream
*kpStdout
, *kpStderr
;
74 wxOutputStream
*kpStdin
;
76 /* wxWidgets standard stuff */