|
|
1.1 root 1: //
2: // nono
1.1.1.2 root 3: // Copyright (C) 2020 nono project
4: // Licensed under nono-license.txt
1.1 root 5: //
6:
7: #pragma once
8:
9: #include "header.h"
10: #include "object.h"
11:
12: // wx のシステムヘッダ内で警告出られてもどうしようもないのでワーニング抑制
1.1.1.2 root 13: #if defined(__clang__)
1.1 root 14: #pragma clang diagnostic push
1.1.1.2 root 15: #pragma clang diagnostic ignored "-Weverything"
16: #else
17: #pragma GCC diagnostic push
18: #pragma GCC diagnostic ignored "-Wcast-qual"
1.1.1.3 ! root 19: #pragma GCC diagnostic ignored "-Wignored-qualifiers"
1.1 root 20: #endif
21:
22: #include <wx/wxprec.h>
23: #ifndef WX_PRECOMP
24: #include <wx/wx.h>
25: #endif
26:
27: // ワーニング抑制ここまで
1.1.1.2 root 28: #if defined(__clang__)
1.1 root 29: #pragma clang diagnostic pop
1.1.1.2 root 30: #else
31: #pragma GCC diagnostic pop
1.1 root 32: #endif
33:
34: // 独自のイベントタイプ
1.1.1.2 root 35: wxDECLARE_EVENT(WXW_EVT_CREATE, wxCommandEvent);
36: wxDECLARE_EVENT(WXW_EVT_HALT_NOTIFY, wxCommandEvent);
1.1 root 37:
38: // OnCreate イベントがあるかのように扱う
39: // イベント登録
40: #define EVT_CREATE(func) EVT_COMMAND(wxID_ANY, WXW_EVT_CREATE, func)
41: // OnCreate イベントを使う場合コンストラクタでコールしておく
42: #define POST_CREATE() do { \
43: wxCommandEvent *event = new wxCommandEvent(WXW_EVT_CREATE); \
44: QueueEvent(event); \
45: } while (0)
46:
47: // フォント種別というかフォントサイズ。
1.1.1.3 ! root 48: // 配列のインデックスとして使うので有効な値を 0 から列挙する。
! 49: enum FontId {
! 50: None = -1,
! 51: _6x12 = 0,
! 52: _8x16,
! 53: Max,
1.1 root 54: };
1.1.1.3 ! root 55: #define FONT_6x12 wxSize(6, 12)
! 56: #define FONT_8x16 wxSize(8, 16)
1.1 root 57:
58: class WXMainFrame;
59: class WXMainView;
60: class WXTextScreen;
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.