screen.h

来自「ears-0.32, linux下有用的语音信号处理工具包」· C头文件 代码 · 共 45 行

H
45
字号
#ifndef Screen_h#define Screen_h#pragma interface#include "others/mystring.h"#include "others/auto_ptr.h"#include "user_interface.h"class screen{public:  static screen* Instance()    { return instance_; }  static screen& InstanceRef() { return *instance_; }  void init ();    // init and draw screen  virtual void close();    void has_query () { has_query_ = true; }  void is_curses () { is_curses_ = true; }  int query (String text, char* keys);  void note (String text);    int getkey ()           { return ui_->get_key(0,0); }  int getkey (char* keys) { return ui_->get_key(0,keys); }protected:  friend bool the_real_main (int, char**);  screen (char* title="")   : is_curses_(false), has_query_(false), title_(title)  { instance_ = this; }  virtual ~screen();            // clear screen, reset state as was before  bool is_curses_, has_query_;    void showfile (char*);  private:  static screen* instance_;  auto_ptr<UserInterface*> ui_;  char* title_;};#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?