• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • applications API Reference
  • KDE Home
  • Contact Us
 

Konsole

  • kde-4.14
  • applications
  • konsole
  • src
Profile.cpp
Go to the documentation of this file.
1 /*
2  This source file is part of Konsole, a terminal emulator.
3 
4  Copyright 2006-2008 by Robert Knight <robertknight@gmail.com>
5 
6  This program is free software; you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation; either version 2 of the License, or
9  (at your option) any later version.
10 
11  This program is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with this program; if not, write to the Free Software
18  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
19  02110-1301 USA.
20 */
21 
22 // Own
23 #include "Profile.h"
24 
25 // Qt
26 #include <QtCore/QTextCodec>
27 
28 // KDE
29 #include <KGlobalSettings>
30 #include <KLocalizedString>
31 
32 // Konsole
33 #include "Enumeration.h"
34 
35 using namespace Konsole;
36 
37 // mappings between property enum values and names
38 //
39 // multiple names are defined for some property values,
40 // in these cases, the "proper" string name comes first,
41 // as that is used when reading/writing profiles from/to disk
42 //
43 // the other names are usually shorter versions for convenience
44 // when parsing konsoleprofile commands
45 static const char GENERAL_GROUP[] = "General";
46 static const char KEYBOARD_GROUP[] = "Keyboard";
47 static const char APPEARANCE_GROUP[] = "Appearance";
48 static const char SCROLLING_GROUP[] = "Scrolling";
49 static const char TERMINAL_GROUP[] = "Terminal Features";
50 static const char CURSOR_GROUP[] = "Cursor Options";
51 static const char INTERACTION_GROUP[] = "Interaction Options";
52 static const char ENCODING_GROUP[] = "Encoding Options";
53 
54 const Profile::PropertyInfo Profile::DefaultPropertyNames[] = {
55  // General
56  { Path , "Path" , 0 , QVariant::String }
57  , { Name , "Name" , GENERAL_GROUP , QVariant::String }
58  , { UntranslatedName, "UntranslatedName" , 0 , QVariant::String }
59  , { Icon , "Icon" , GENERAL_GROUP , QVariant::String }
60  , { Command , "Command" , 0 , QVariant::String }
61  , { Arguments , "Arguments" , 0 , QVariant::StringList }
62  , { MenuIndex, "MenuIndex" , 0, QVariant::String }
63  , { Environment , "Environment" , GENERAL_GROUP , QVariant::StringList }
64  , { Directory , "Directory" , GENERAL_GROUP , QVariant::String }
65  , { LocalTabTitleFormat , "LocalTabTitleFormat" , GENERAL_GROUP , QVariant::String }
66  , { LocalTabTitleFormat , "tabtitle" , 0 , QVariant::String }
67  , { RemoteTabTitleFormat , "RemoteTabTitleFormat" , GENERAL_GROUP , QVariant::String }
68  , { ShowTerminalSizeHint , "ShowTerminalSizeHint" , GENERAL_GROUP , QVariant::Bool }
69  , { StartInCurrentSessionDir , "StartInCurrentSessionDir" , GENERAL_GROUP , QVariant::Bool }
70  , { SilenceSeconds, "SilenceSeconds" , GENERAL_GROUP , QVariant::Int }
71  , { TerminalColumns, "TerminalColumns" , GENERAL_GROUP , QVariant::Int }
72  , { TerminalRows, "TerminalRows" , GENERAL_GROUP , QVariant::Int }
73 
74  // Appearance
75  , { Font , "Font" , APPEARANCE_GROUP , QVariant::Font }
76  , { ColorScheme , "ColorScheme" , APPEARANCE_GROUP , QVariant::String }
77  , { ColorScheme , "colors" , 0 , QVariant::String }
78  , { AntiAliasFonts, "AntiAliasFonts" , APPEARANCE_GROUP , QVariant::Bool }
79  , { BoldIntense, "BoldIntense", APPEARANCE_GROUP, QVariant::Bool }
80  , { LineSpacing , "LineSpacing" , APPEARANCE_GROUP , QVariant::Int }
81 
82  // Keyboard
83  , { KeyBindings , "KeyBindings" , KEYBOARD_GROUP , QVariant::String }
84 
85  // Scrolling
86  , { HistoryMode , "HistoryMode" , SCROLLING_GROUP , QVariant::Int }
87  , { HistorySize , "HistorySize" , SCROLLING_GROUP , QVariant::Int }
88  , { ScrollBarPosition , "ScrollBarPosition" , SCROLLING_GROUP , QVariant::Int }
89  , { ScrollFullPage , "ScrollFullPage" , SCROLLING_GROUP , QVariant::Bool }
90 
91  // Terminal Features
92  , { BlinkingTextEnabled , "BlinkingTextEnabled" , TERMINAL_GROUP , QVariant::Bool }
93  , { FlowControlEnabled , "FlowControlEnabled" , TERMINAL_GROUP , QVariant::Bool }
94  , { BidiRenderingEnabled , "BidiRenderingEnabled" , TERMINAL_GROUP , QVariant::Bool }
95  , { BlinkingCursorEnabled , "BlinkingCursorEnabled" , TERMINAL_GROUP , QVariant::Bool }
96  , { BellMode , "BellMode" , TERMINAL_GROUP , QVariant::Int }
97 
98  // Cursor
99  , { UseCustomCursorColor , "UseCustomCursorColor" , CURSOR_GROUP , QVariant::Bool}
100  , { CursorShape , "CursorShape" , CURSOR_GROUP , QVariant::Int}
101  , { CustomCursorColor , "CustomCursorColor" , CURSOR_GROUP , QVariant::Color }
102 
103  // Interaction
104  , { WordCharacters , "WordCharacters" , INTERACTION_GROUP , QVariant::String }
105  , { TripleClickMode , "TripleClickMode" , INTERACTION_GROUP , QVariant::Int }
106  , { UnderlineLinksEnabled , "UnderlineLinksEnabled" , INTERACTION_GROUP , QVariant::Bool }
107  , { OpenLinksByDirectClickEnabled , "OpenLinksByDirectClickEnabled" , INTERACTION_GROUP , QVariant::Bool }
108  , { CtrlRequiredForDrag, "CtrlRequiredForDrag" , INTERACTION_GROUP , QVariant::Bool }
109  , { AutoCopySelectedText , "AutoCopySelectedText" , INTERACTION_GROUP , QVariant::Bool }
110  , { TrimTrailingSpacesInSelectedText , "TrimTrailingSpacesInSelectedText" , INTERACTION_GROUP , QVariant::Bool }
111  , { PasteFromSelectionEnabled , "PasteFromSelectionEnabled" , INTERACTION_GROUP , QVariant::Bool }
112  , { PasteFromClipboardEnabled , "PasteFromClipboardEnabled" , INTERACTION_GROUP , QVariant::Bool }
113  , { MiddleClickPasteMode, "MiddleClickPasteMode" , INTERACTION_GROUP , QVariant::Int }
114  , { MouseWheelZoomEnabled, "MouseWheelZoomEnabled", INTERACTION_GROUP, QVariant::Bool }
115 
116  // Encoding
117  , { DefaultEncoding , "DefaultEncoding" , ENCODING_GROUP , QVariant::String }
118 
119  , { (Property)0 , 0 , 0, QVariant::Invalid }
120 };
121 
122 QHash<QString, Profile::PropertyInfo> Profile::PropertyInfoByName;
123 QHash<Profile::Property, Profile::PropertyInfo> Profile::PropertyInfoByProperty;
124 
125 void Profile::fillTableWithDefaultNames()
126 {
127  static bool filledDefaults = false;
128 
129  if (filledDefaults)
130  return;
131 
132  const PropertyInfo* iter = DefaultPropertyNames;
133  while (iter->name != 0) {
134  registerProperty(*iter);
135  iter++;
136  }
137 
138  filledDefaults = true;
139 }
140 
141 FallbackProfile::FallbackProfile()
142  : Profile()
143 {
144  // Fallback settings
145  setProperty(Name, i18n("Shell"));
146  setProperty(UntranslatedName, "Shell");
147  // magic path for the fallback profile which is not a valid
148  // non-directory file name
149  setProperty(Path, "FALLBACK/");
150  setProperty(Command, qgetenv("SHELL"));
151  setProperty(Arguments, QStringList() << qgetenv("SHELL"));
152  setProperty(Icon, "utilities-terminal");
153  setProperty(Environment, QStringList() << "TERM=xterm");
154  setProperty(LocalTabTitleFormat, "%d : %n");
155  setProperty(RemoteTabTitleFormat, "(%u) %H");
156  setProperty(ShowTerminalSizeHint, true);
157  setProperty(StartInCurrentSessionDir, true);
158  setProperty(MenuIndex, "0");
159  setProperty(SilenceSeconds, 10);
160  setProperty(TerminalColumns, 80);
161  setProperty(TerminalRows, 40);
162  setProperty(MouseWheelZoomEnabled, true);
163 
164  setProperty(KeyBindings, "default");
165  setProperty(ColorScheme, "Linux"); //use DarkPastels when is start support blue ncurses UI properly
166  setProperty(Font, KGlobalSettings::fixedFont());
167 
168  setProperty(HistoryMode, Enum::FixedSizeHistory);
169  setProperty(HistorySize, 1000);
170  setProperty(ScrollBarPosition, Enum::ScrollBarRight);
171  setProperty(ScrollFullPage, false);
172 
173  setProperty(FlowControlEnabled, true);
174  setProperty(BlinkingTextEnabled, true);
175  setProperty(UnderlineLinksEnabled, true);
176  setProperty(OpenLinksByDirectClickEnabled, false);
177  setProperty(CtrlRequiredForDrag, true);
178  setProperty(AutoCopySelectedText, false);
179  setProperty(TrimTrailingSpacesInSelectedText, false);
180  setProperty(PasteFromSelectionEnabled, true);
181  setProperty(PasteFromClipboardEnabled, false);
182  setProperty(MiddleClickPasteMode, Enum::PasteFromX11Selection);
183  setProperty(TripleClickMode, Enum::SelectWholeLine);
184 
185  setProperty(BlinkingCursorEnabled, false);
186  setProperty(BidiRenderingEnabled, true);
187  setProperty(LineSpacing, 0);
188  setProperty(CursorShape, Enum::BlockCursor);
189  setProperty(UseCustomCursorColor, false);
190  setProperty(CustomCursorColor, Qt::black);
191  setProperty(BellMode, Enum::NotifyBell);
192 
193  setProperty(DefaultEncoding, QString(QTextCodec::codecForLocale()->name()));
194  setProperty(AntiAliasFonts, true);
195  setProperty(BoldIntense, true);
196 
197  // default taken from KDE 3
198  setProperty(WordCharacters, ":@-./_~?&=%+#");
199 
200  // Fallback should not be shown in menus
201  setHidden(true);
202 }
203 Profile::Profile(Profile::Ptr parent)
204  : _parent(parent)
205  , _hidden(false)
206 {
207 }
208 void Profile::clone(Profile::Ptr profile, bool differentOnly)
209 {
210  const PropertyInfo* properties = DefaultPropertyNames;
211  while (properties->name != 0) {
212  Property current = properties->property;
213  QVariant otherValue = profile->property<QVariant>(current);
214  switch (current) {
215  case Name:
216  case Path:
217  break;
218  default:
219  if (!differentOnly ||
220  property<QVariant>(current) != otherValue) {
221  setProperty(current, otherValue);
222  }
223  }
224  properties++;
225  }
226 }
227 Profile::~Profile()
228 {
229 }
230 bool Profile::isHidden() const
231 {
232  return _hidden;
233 }
234 void Profile::setHidden(bool hidden)
235 {
236  _hidden = hidden;
237 }
238 
239 void Profile::setParent(Profile::Ptr parent)
240 {
241  _parent = parent;
242 }
243 const Profile::Ptr Profile::parent() const
244 {
245  return _parent;
246 }
247 
248 bool Profile::isEmpty() const
249 {
250  return _propertyValues.isEmpty();
251 }
252 QHash<Profile::Property, QVariant> Profile::setProperties() const
253 {
254  return _propertyValues;
255 }
256 void Profile::setProperty(Property property , const QVariant& value)
257 {
258  _propertyValues.insert(property, value);
259 }
260 bool Profile::isPropertySet(Property property) const
261 {
262  return _propertyValues.contains(property);
263 }
264 
265 Profile::Property Profile::lookupByName(const QString& name)
266 {
267  // insert default names into table the first time this is called
268  fillTableWithDefaultNames();
269 
270  return PropertyInfoByName[name.toLower()].property;
271 }
272 
273 void Profile::registerProperty(const PropertyInfo& info)
274 {
275  PropertyInfoByName.insert(QString(info.name).toLower(), info);
276 
277  // only allow one property -> name map
278  // (multiple name -> property mappings are allowed though)
279  if (!PropertyInfoByProperty.contains(info.property))
280  PropertyInfoByProperty.insert(info.property, info);
281 }
282 
283 int Profile::menuIndexAsInt() const
284 {
285  bool ok;
286  int index = menuIndex().toInt(&ok, 10);
287  if (ok)
288  return index;
289  else
290  return 0;
291 }
292 
293 const QStringList Profile::propertiesInfoList() const
294 {
295  QStringList info;
296  const PropertyInfo* iter = DefaultPropertyNames;
297  while (iter->name != 0) {
298  info << QString(iter->name) + " : " + QString(QVariant(iter->type).typeName());
299  iter++;
300  }
301 
302  return info;
303 }
304 
305 QHash<Profile::Property, QVariant> ProfileCommandParser::parse(const QString& input)
306 {
307  QHash<Profile::Property, QVariant> changes;
308 
309  // regular expression to parse profile change requests.
310  //
311  // format: property=value;property=value ...
312  //
313  // where 'property' is a word consisting only of characters from A-Z
314  // where 'value' is any sequence of characters other than a semi-colon
315  //
316  static QRegExp regExp("([a-zA-Z]+)=([^;]+)");
317 
318  int offset = 0;
319  while (regExp.indexIn(input, offset) != -1) {
320  if (regExp.capturedTexts().count() == 3) {
321  Profile::Property property = Profile::lookupByName(
322  regExp.capturedTexts()[1]);
323  const QString value = regExp.capturedTexts()[2];
324  changes.insert(property, value);
325  }
326 
327  offset = input.indexOf(';', offset) + 1;
328  if (offset == 0)
329  break;
330  }
331 
332  return changes;
333 }
334 
335 void ProfileGroup::updateValues()
336 {
337  const PropertyInfo* properties = Profile::DefaultPropertyNames;
338  while (properties->name != 0) {
339  // the profile group does not store a value for some properties
340  // (eg. name, path) if even they are equal between profiles -
341  //
342  // the exception is when the group has only one profile in which
343  // case it behaves like a standard Profile
344  if (_profiles.count() > 1 &&
345  !canInheritProperty(properties->property)) {
346  properties++;
347  continue;
348  }
349 
350  QVariant value;
351  for (int i = 0; i < _profiles.count(); i++) {
352  QVariant profileValue = _profiles[i]->property<QVariant>(properties->property);
353  if (value.isNull())
354  value = profileValue;
355  else if (value != profileValue) {
356  value = QVariant();
357  break;
358  }
359  }
360  Profile::setProperty(properties->property, value);
361  properties++;
362  }
363 }
364 void ProfileGroup::setProperty(Property property, const QVariant& value)
365 {
366  if (_profiles.count() > 1 && !canInheritProperty(property))
367  return;
368 
369  Profile::setProperty(property, value);
370  foreach(Profile::Ptr profile, _profiles) {
371  profile->setProperty(property, value);
372  }
373 }
374 
Konsole::Profile::setParent
void setParent(Ptr parent)
Changes the parent profile.
Definition: Profile.cpp:239
Konsole::Profile::HistoryMode
(HistoryModeEnum) Specifies the storage type used for keeping the output produced by terminal session...
Definition: Profile.h:137
Konsole::Profile::DefaultEncoding
(String) Default text codec
Definition: Profile.h:221
QString::indexOf
int indexOf(QChar ch, int from, Qt::CaseSensitivity cs) const
Konsole::Profile::AntiAliasFonts
(bool) Whether fonts should be aliased or not
Definition: Profile.h:223
QHash::insert
iterator insert(const Key &key, const T &value)
Konsole::Profile::ShowTerminalSizeHint
(bool) Specifies whether show hint for terminal size after resizing the application window...
Definition: Profile.h:120
APPEARANCE_GROUP
static const char APPEARANCE_GROUP[]
Definition: Profile.cpp:47
GENERAL_GROUP
static const char GENERAL_GROUP[]
Definition: Profile.cpp:45
Konsole::Profile::FlowControlEnabled
(bool) Specifies whether the flow control keys (typically Ctrl+S, Ctrl+Q) have any effect...
Definition: Profile.h:165
Konsole::Profile::CustomCursorColor
(QColor) The color used by terminal displays to draw the cursor.
Definition: Profile.h:187
CURSOR_GROUP
static const char CURSOR_GROUP[]
Definition: Profile.cpp:50
TERMINAL_GROUP
static const char TERMINAL_GROUP[]
Definition: Profile.cpp:49
Konsole::Profile::RemoteTabTitleFormat
(QString) The format used for tab titles when the session is running a remote command (eg...
Definition: Profile.h:116
Konsole::Profile::TrimTrailingSpacesInSelectedText
(bool) If true, trailing spaces are trimmed in selected text
Definition: Profile.h:209
Konsole::Profile::~Profile
virtual ~Profile()
Definition: Profile.cpp:227
Konsole::Profile::MenuIndex
Index of profile in the File Menu WARNING: this is currently an internal field, which is expected to ...
Definition: Profile.h:248
Konsole::Profile::isHidden
bool isHidden() const
Returns true if this is a 'hidden' profile which should not be displayed in menus or saved to disk...
Definition: Profile.cpp:230
Konsole::Profile::KeyBindings
(QString) The name of the key bindings.
Definition: Profile.h:131
Konsole::Profile::setHidden
void setHidden(bool hidden)
Specifies whether this is a hidden profile.
Definition: Profile.cpp:234
Konsole::Enum::PasteFromX11Selection
Paste from X11 Selection.
Definition: Enumeration.h:102
Konsole::Profile::WordCharacters
(QString) A string consisting of the characters used to delimit words when selecting text in the term...
Definition: Profile.h:191
Konsole::Enum::SelectWholeLine
Select the whole line underneath the cursor.
Definition: Enumeration.h:94
Konsole::Profile::SilenceSeconds
(int) Specifies the threshold of detected silence in seconds.
Definition: Profile.h:232
Konsole::Profile::MiddleClickPasteMode
(MiddleClickPasteModeEnum) Specifies the source from which mouse middle click pastes data...
Definition: Profile.h:219
Konsole::ProfileGroup::updateValues
void updateValues()
Updates the property values in this ProfileGroup to match those from the group's profiles() ...
Definition: Profile.cpp:335
Konsole::Profile::Font
(QFont) The font to use in terminal displays using this profile.
Definition: Profile.h:122
Konsole::Profile
Represents a terminal set-up which can be used to set the initial state of new terminal sessions or a...
Definition: Profile.h:60
Konsole::Profile::clone
void clone(Ptr profile, bool differentOnly=true)
Copies all properties except Name and Path from the specified profile into this profile.
Definition: Profile.cpp:208
Konsole::Profile::Property
Property
This enum describes the available properties which a Profile may consist of.
Definition: Profile.h:77
QTextCodec::codecForLocale
QTextCodec * codecForLocale()
Konsole::Profile::PasteFromClipboardEnabled
(bool) If true, middle mouse button pastes from Clipboard
Definition: Profile.h:213
Konsole::Profile::BlinkingTextEnabled
(bool) Specifies whether text in terminal displays is allowed to blink.
Definition: Profile.h:161
Konsole::Profile::PasteFromSelectionEnabled
(bool) If true, middle mouse button pastes from X Selection
Definition: Profile.h:211
Konsole::Enum::BlockCursor
Use a solid rectangular block to draw the cursor.
Definition: Enumeration.h:82
Konsole::Profile::Command
(QString) The command to execute ( excluding arguments ) when creating a new terminal session using t...
Definition: Profile.h:93
Konsole::Profile::UseCustomCursorColor
(bool) If true, terminal displays use a fixed color to draw the cursor, specified by the CustomCursor...
Definition: Profile.h:177
QRegExp::indexIn
int indexIn(const QString &str, int offset, CaretMode caretMode) const
Konsole::Profile::UntranslatedName
(QString) The untranslated name of this profile.
Definition: Profile.h:85
QRegExp
Konsole::Enum::NotifyBell
trigger system notification.
Definition: Enumeration.h:116
Konsole::Profile::BlinkingCursorEnabled
(bool) Specifies whether the cursor blinks ( in a manner similar to text editing applications ) ...
Definition: Profile.h:172
QList::count
int count(const T &value) const
Konsole::Profile::AutoCopySelectedText
(bool) If true, automatically copy selected text into the clipboard
Definition: Profile.h:207
Konsole::Profile::StartInCurrentSessionDir
(bool) Whether new sessions should be started in the same directory as the currently active session...
Definition: Profile.h:230
QVariant::isNull
bool isNull() const
INTERACTION_GROUP
static const char INTERACTION_GROUP[]
Definition: Profile.cpp:51
Konsole::Profile::UnderlineLinksEnabled
(bool) If true, text that matches a link or an email address is underlined when hovered by the mouse ...
Definition: Profile.h:201
Konsole::Profile::BoldIntense
(bool) Whether character with intense colors should be rendered in bold font or just in bright color...
Definition: Profile.h:226
SCROLLING_GROUP
static const char SCROLLING_GROUP[]
Definition: Profile.cpp:48
QHash
Konsole::Profile::ScrollFullPage
(bool) Specifies whether the PageUp/Down will scroll the full height or half height.
Definition: Profile.h:153
QRegExp::capturedTexts
QStringList capturedTexts() const
QString::toInt
int toInt(bool *ok, int base) const
KEYBOARD_GROUP
static const char KEYBOARD_GROUP[]
Definition: Profile.cpp:46
Konsole::Profile::Profile
Profile(Ptr parent=Ptr())
Constructs a new profile.
Definition: Profile.cpp:203
Konsole::Profile::LineSpacing
(int) Specifies the pixels between the terminal lines.
Definition: Profile.h:168
Konsole::Profile::Arguments
(QStringList) The arguments which are passed to the program specified by the Command property when cr...
Definition: Profile.h:98
Konsole::Profile::Icon
(QString) The name of the icon associated with this profile.
Definition: Profile.h:89
Konsole::Profile::BellMode
(BellModeEnum) Specifies the behavior of bell.
Definition: Profile.h:237
Konsole::Profile::TripleClickMode
(TripleClickModeEnum) Specifies which part of current line should be selected with triple click actio...
Definition: Profile.h:197
QString
Enumeration.h
Konsole::Profile::lookupByName
static Property lookupByName(const QString &name)
Returns the element from the Property enum associated with the specified name.
Definition: Profile.cpp:265
Konsole::Profile::name
QString name() const
Convenience method for property(Profile::Name)
Definition: Profile.h:340
Konsole::Profile::BidiRenderingEnabled
(bool) Specifies whether the terminal will enable Bidirectional text display
Definition: Profile.h:157
QStringList
QString::toLower
QString toLower() const
Konsole::Profile::isPropertySet
virtual bool isPropertySet(Property property) const
Returns true if the specified property has been set in this Profile instance.
Definition: Profile.cpp:260
Konsole::ProfileCommandParser::parse
QHash< Profile::Property, QVariant > parse(const QString &input)
Parses an input string consisting of property names and assigned values and returns a table of proper...
Definition: Profile.cpp:305
Konsole::Profile::Ptr
KSharedPtr< Profile > Ptr
Definition: Profile.h:67
Konsole::Profile::menuIndexAsInt
int menuIndexAsInt() const
Definition: Profile.cpp:283
Konsole::Profile::setProperties
virtual QHash< Property, QVariant > setProperties() const
Returns a map of the properties set in this Profile instance.
Definition: Profile.cpp:252
Konsole::Profile::HistorySize
(int) Specifies the number of lines of output to remember in terminal sessions using this profile...
Definition: Profile.h:143
Konsole::Profile::CursorShape
(CursorShapeEnum) The shape used by terminal displays to represent the cursor.
Definition: Profile.h:183
Konsole::Profile::isEmpty
bool isEmpty() const
Returns true if no properties have been set in this Profile instance.
Definition: Profile.cpp:248
Konsole::Profile::parent
const Ptr parent() const
Returns the parent profile.
Definition: Profile.cpp:243
QHash::isEmpty
bool isEmpty() const
Konsole::Profile::ScrollBarPosition
(ScrollBarPositionEnum) Specifies the position of the scroll bar in terminal displays using this prof...
Definition: Profile.h:149
ENCODING_GROUP
static const char ENCODING_GROUP[]
Definition: Profile.cpp:52
Konsole::Profile::TerminalColumns
(int) Specifies the preferred columns.
Definition: Profile.h:239
QVariant::typeName
const char * typeName() const
Konsole::FallbackProfile::FallbackProfile
FallbackProfile()
Definition: Profile.cpp:141
Konsole::Enum::FixedSizeHistory
A fixed number of lines of output are remembered.
Definition: Enumeration.h:46
Konsole::Profile::MouseWheelZoomEnabled
(bool) If true, mouse wheel scroll with Ctrl key pressed increases/decreases the terminal font size...
Definition: Profile.h:252
Konsole::Enum::ScrollBarRight
Show the scroll-bar on the right of the terminal display.
Definition: Enumeration.h:62
QHash::contains
bool contains(const Key &key) const
Konsole::Profile::propertiesInfoList
const QStringList propertiesInfoList() const
Return a list of all properties names and their type (for use with -p option).
Definition: Profile.cpp:293
Konsole::Profile::Path
(QString) Path to the profile's configuration file on-disk.
Definition: Profile.h:79
Konsole::Profile::LocalTabTitleFormat
(QString) The format used for tab titles when running normal commands.
Definition: Profile.h:112
Konsole::Profile::menuIndex
QString menuIndex() const
Convenience method for property(Profile::MenuIndex)
Definition: Profile.h:500
Konsole::Profile::TerminalRows
(int) Specifies the preferred rows.
Definition: Profile.h:241
Konsole::Profile::OpenLinksByDirectClickEnabled
(bool) If true, links can be opened by direct mouse click.
Definition: Profile.h:203
Konsole::Profile::setProperty
virtual void setProperty(Property property, const QVariant &value)
Sets the value of the specified property to value.
Definition: Profile.cpp:256
Konsole::Profile::Name
(QString) The descriptive name of this profile.
Definition: Profile.h:81
Profile.h
Konsole::ColorScheme
Represents a color scheme for a terminal display.
Definition: ColorScheme.h:72
Konsole::ProfileGroup::setProperty
void setProperty(Property property, const QVariant &value)
Sets the value of property in each of the group's profiles to value.
Definition: Profile.cpp:364
QVariant
Konsole::Profile::CtrlRequiredForDrag
(bool) If true, control key must be pressed to click and drag selected text.
Definition: Profile.h:205
Konsole::Profile::Environment
(QStringList) Additional environment variables (in the form of NAME=VALUE pairs) which are passed to ...
Definition: Profile.h:104
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sat May 9 2020 03:56:27 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

Konsole

Skip menu "Konsole"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

applications API Reference

Skip menu "applications API Reference"
  •   kate
  •       kate
  •   KTextEditor
  •   Kate
  • Konsole

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal