VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/widgets/UILineTextEdit.h@ 76553

Last change on this file since 76553 was 76553, checked in by vboxsync, 5 years ago

scm --update-copyright-year

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.0 KB
Line 
1/* $Id: UILineTextEdit.h 76553 2019-01-01 01:45:53Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - UILineTextEdit class declaration.
4 */
5
6/*
7 * Copyright (C) 2009-2019 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#ifndef __UILineTextEdit_h__
19#define __UILineTextEdit_h__
20#ifndef RT_WITHOUT_PRAGMA_ONCE
21# pragma once
22#endif
23
24/* VBox includes */
25#include "QIDialog.h"
26#include "QIWithRetranslateUI.h"
27
28/* Qt includes */
29#include <QPushButton>
30
31/* Qt forward declarations */
32class QTextEdit;
33class QDialogButtonBox;
34
35////////////////////////////////////////////////////////////////////////////////
36// UITextEditor
37
38class UITextEditor: public QIWithRetranslateUI<QIDialog>
39{
40 Q_OBJECT;
41
42public:
43 UITextEditor(QWidget *pParent = NULL);
44
45 void setText(const QString& strText);
46 QString text() const;
47
48protected:
49 void retranslateUi();
50
51private slots:
52 void open();
53
54private:
55 /* Private member vars */
56 QTextEdit *m_pTextEdit;
57 QDialogButtonBox *m_pButtonBox;
58 QPushButton *m_pOpenButton;
59};
60
61////////////////////////////////////////////////////////////////////////////////
62// UILineTextEdit
63
64class UILineTextEdit: public QIWithRetranslateUI<QPushButton>
65{
66 Q_OBJECT;
67
68signals:
69
70 /* Notifier: Editing stuff: */
71 void sigFinished(QWidget *pThis);
72
73public:
74 UILineTextEdit(QWidget *pParent = NULL);
75
76 void setText(const QString& strText) { m_strText = strText; }
77 QString text() const { return m_strText; }
78
79protected:
80 void retranslateUi();
81
82private slots:
83 void edit();
84
85private:
86 /* Private member vars */
87 QString m_strText;
88};
89
90#endif /* __UILineTextEdit_h__ */
91
Note: See TracBrowser for help on using the repository browser.

© 2023 Oracle
ContactPrivacy policyTerms of Use