⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fax_list.h

📁 用于使用moden进行传真的源代码
💻 H
字号:
/* Copyright (C) 2001 2002 Chris VineThis program is distributed under the General Public Licence, version 2.For particulars of this and relevant disclaimers see the fileCOPYING distributed with the source files.*/#ifndef FAX_LIST_H#define FAX_LIST_H#include "prog_defs.h"#include <string>#include <utility>#include <gtkmm/window.h>#include <gtkmm/table.h>#include <gtkmm/button.h>#include <gtkmm/buttonbox.h>#include <gtkmm/treeview.h>#include <gtkmm/treemodel.h>#include <gtkmm/treemodelcolumn.h>#include <gtkmm/liststore.h>#include <gtkmm/scrolledwindow.h>#include <gtkmm/entry.h>#include <gtkmm/label.h>#include <gtkmm/toolbar.h>#include <gtkmm/box.h>#include <glibmm/ustring.h>#if GTKMM_VERSION >= 24#include <gtkmm/toolbutton.h>#endif#include "sem_sync.h"class FaxListModelColumns: public Gtk::TreeModel::ColumnRecord {  Gtk::TreeModelColumn<std::string> fax_name;  Gtk::TreeModelColumn<Glib::ustring> fax_description;  // private constructor - only FaxListDialog can create objects of this class  FaxListModelColumns(void) {add(fax_name); add(fax_description);}public:  friend class FaxListDialog;};// this class is modeless, and does not have an exec() method// it is self-owning and will delete itselfclass FaxListDialog: public Gtk::Window {public:  enum Mode {received, sent};private:  Mode mode;  static int is_fax_received_list;  static int is_fax_sent_list;  const int standard_size;  Sem_sync fax_basename_sem;  std::string fax_basename;#if GTKMM_VERSION >= 24  Gtk::ToolButton* print_button_p;  Gtk::ToolButton* view_button_p;  Gtk::ToolButton* describe_button_p;  Gtk::ToolButton* delete_button_p;#else  Gtk::Button* print_button_p;  Gtk::Button* view_button_p;  Gtk::Button* describe_button_p;  Gtk::Button* delete_button_p;#endif  Gtk::VBox fax_list_box;  Gtk::Table table;  Gtk::Toolbar tool_bar;  Gtk::ScrolledWindow fax_list_scroll_window;  Gtk::Button close_button;  Gtk::HButtonBox button_box;  FaxListModelColumns model_columns;  Gtk::TreeView tree_view;  Glib::RefPtr<Gtk::ListStore> list_store_r;  void get_fax_list_rows(void);  void close_slot(void);  void set_buttons_slot(void);  void describe_fax_prompt(void);  void describe_fax_prompt_witharg(gint) {describe_fax_prompt();}  void describe_fax(const Glib::ustring&);  void write_from_stdin(int);  std::pair<const char*, char* const*> get_print_from_stdin_parms(void);  std::pair<const char*, char* const*> get_fax_to_ps_parms(const std::string&, bool);  std::pair<const char*, char* const*> get_ps_viewer_parms(const char*);  void print_fax_prompt(void);  void print_fax(void);  void print_fax_thread(void);  void view_fax(void);  void view_fax_thread(void);  void delete_fax_prompt(void);  void delete_fax(void);  void delete_parms(std::pair<const char*, char* const*>);protected:  virtual bool on_delete_event(GdkEventAny*);public:  static int get_is_fax_received_list(void) {return is_fax_received_list;}  static int get_is_fax_sent_list(void) {return is_fax_sent_list;}  void refresh_slot(void);  FaxListDialog(Mode, const int standard_size_);  ~FaxListDialog(void);};class DescriptionDialog: public Gtk::Window {  bool in_exec_loop;  Gtk::Button ok_button;  Gtk::Button cancel_button;  Gtk::HButtonBox button_box;  Gtk::Label label;  Gtk::Table table;  Gtk::Entry entry;  Gtk::Window& parent;protected:  virtual bool on_delete_event(GdkEventAny*);  virtual bool on_key_press_event(GdkEventKey*);public:  void selected(bool);  sigc::signal1<void, const Glib::ustring&> accepted;  void exec(void);  DescriptionDialog(const int standard_size, const std::string& text, Gtk::Window& window);};#endif

⌨️ 快捷键说明

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