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

📄 options_window.h

📁 Linux平台下的内核及程序调试器
💻 H
字号:
/* ----------------------------------------------------------------------  * Definition of class OptionsWindow                     options_window.h * A container class for each tool's options / flags 'pane'. * Not modal, so user can keep it open and change flags as they work. * ----------------------------------------------------------------------  * This file is part of Valkyrie, a front-end for Valgrind * Copyright (c) 2000-2006, OpenWorks LLP <info@open-works.co.uk> * This program is released under the terms of the GNU GPL v.2 * See the file LICENSE.GPL for the full license details. */#ifndef __VK_OPTIONS_WINDOW_H#define __VK_OPTIONS_WINDOW_H#include <qdict.h>#include <qlistbox.h>#include <qmainwindow.h>#include <qpushbutton.h>#include <qwidgetstack.h>#include "options_page.h"/* class Categories ---------------------------------------------------- */class Categories : public QListBox{public:   Categories( QWidget *parent );   int categHeight();private:   int m_categht;};/* class CategItem ----------------------------------------------------- */class CategItem : public QListBoxItem {public:   CategItem( QListBox * parent, OptionsPage * op,              const QString &text, int id );   virtual int height( const QListBox * ) const;   int catId() const;   void setWidget( OptionsPage * op );   OptionsPage * page() const;protected:   void paint( QPainter *p );private:   int          m_catid;   OptionsPage* m_optpage;};/* class OptionsWindow ------------------------------------------------- */class OptionsWindow : public QMainWindow{   Q_OBJECTpublic:   OptionsWindow( QWidget* parent=0 );   ~OptionsWindow();   void showPage( int catid );signals:   void flagsChanged();protected:   void closeEvent( QCloseEvent * );   void moveEvent( QMoveEvent * );private slots:   void accept();   void reject();   bool apply();   void modified();   void resetDefaults();   void save();   void categoryClicked( QListBoxItem * );private:   void adjustPosition();   void setCategory( int catid );   void addCategory( VkObject* obj );   OptionsPage* mkOptionsPage( int catid );private:   /* remember where user put the window */   int m_xpos, m_ypos;   QString      m_capt;   QPushButton* m_applyButton;   QPushButton* m_resetButton;   QPushButton* m_saveButton;   /* so we can iterate over the vkOptions widgets */   QPtrList<OptionsPage> m_optPages;   Categories*           m_categories;   QWidgetStack*         m_wStack;};#endif

⌨️ 快捷键说明

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