Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Konsole
Commits
e728c533
Commit
e728c533
authored
May 02, 2007
by
Robert Knight
Browse files
Load, save & apply blinking cursor setting.
svn path=/branches/work/konsole-split-view/; revision=660232
parent
8086851f
Changes
6
Hide whitespace changes
Inline
Side-by-side
konsole/EditProfileDialog.cpp
View file @
e728c533
...
...
@@ -349,6 +349,9 @@ void EditProfileDialog::setupAdvancedPage(const Profile* profile)
_ui
->
enableFlowControlButton
->
setChecked
(
profile
->
property
(
Profile
::
FlowControlEnabled
).
value
<
bool
>
()
);
_ui
->
enableResizeWindowButton
->
setChecked
(
profile
->
property
(
Profile
::
AllowProgramsToResizeWindow
)
.
value
<
bool
>
()
);
_ui
->
enableBlinkingCursorButton
->
setChecked
(
profile
->
property
(
Profile
::
BlinkingCursorEnabled
)
.
value
<
bool
>
()
);
// signals and slots
connect
(
_ui
->
enableBlinkingTextButton
,
SIGNAL
(
toggled
(
bool
))
,
this
,
SLOT
(
toggleBlinkingText
(
bool
))
);
...
...
@@ -356,6 +359,12 @@ void EditProfileDialog::setupAdvancedPage(const Profile* profile)
SLOT
(
toggleFlowControl
(
bool
))
);
connect
(
_ui
->
enableResizeWindowButton
,
SIGNAL
(
toggled
(
bool
))
,
this
,
SLOT
(
toggleResizeWindow
(
bool
))
);
connect
(
_ui
->
enableBlinkingCursorButton
,
SIGNAL
(
toggled
(
bool
))
,
this
,
SLOT
(
toggleBlinkingCursor
(
bool
))
);
}
void
EditProfileDialog
::
toggleBlinkingCursor
(
bool
enable
)
{
_tempProfile
->
setProperty
(
Profile
::
BlinkingCursorEnabled
,
enable
);
}
void
EditProfileDialog
::
toggleBlinkingText
(
bool
enable
)
{
...
...
konsole/EditProfileDialog.h
View file @
e728c533
...
...
@@ -108,6 +108,7 @@ private slots:
void
toggleBlinkingText
(
bool
);
void
toggleFlowControl
(
bool
);
void
toggleResizeWindow
(
bool
);
void
toggleBlinkingCursor
(
bool
);
private:
// initialize various pages of the dialog
...
...
konsole/EditProfileDialog.ui
View file @
e728c533
...
...
@@ -580,6 +580,13 @@
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="enableBlinkingCursorButton" >
<property name="text" >
<string>Blinking cursor</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
...
...
konsole/SessionManager.cpp
View file @
e728c533
...
...
@@ -175,9 +175,10 @@ bool KDE4ProfileWriter::writeProfile(const QString& path , const Profile* profil
writeStandardElement
(
scrolling
,
"HistorySize"
,
profile
,
Profile
::
HistorySize
);
writeStandardElement
(
scrolling
,
"ScrollBarPosition"
,
profile
,
Profile
::
ScrollBarPosition
);
KConfigGroup
terminalFeatures
=
config
.
group
(
"TerminalFeatures"
);
KConfigGroup
terminalFeatures
=
config
.
group
(
"Terminal
Features"
);
writeStandardElement
(
terminalFeatures
,
"FlowControl"
,
profile
,
Profile
::
FlowControlEnabled
);
writeStandardElement
(
terminalFeatures
,
"BlinkingCursor"
,
profile
,
Profile
::
BlinkingCursorEnabled
);
return
true
;
}
...
...
@@ -235,6 +236,7 @@ bool KDE4ProfileReader::readProfile(const QString& path , Profile* profile)
KConfigGroup
terminalFeatures
=
config
.
group
(
"Terminal Features"
);
readStandardElement
(
terminalFeatures
,
"FlowControl"
,
profile
,
Profile
::
FlowControlEnabled
);
readStandardElement
(
terminalFeatures
,
"BlinkingCursor"
,
profile
,
Profile
::
BlinkingCursorEnabled
);
return
true
;
}
...
...
@@ -271,13 +273,9 @@ bool KDE3ProfileReader::readProfile(const QString& path , Profile* profile)
{
const
QString
&
fullCommand
=
config
->
readEntry
(
"Exec"
);
ShellCommand
shellCommand
(
fullCommand
);
qDebug
()
<<
"full command = "
<<
fullCommand
;
profile
->
setProperty
(
Profile
::
Command
,
shellCommand
.
command
());
profile
->
setProperty
(
Profile
::
Arguments
,
shellCommand
.
arguments
());
qDebug
()
<<
"command = "
<<
profile
->
command
();
qDebug
()
<<
"argumetns = "
<<
profile
->
arguments
();
}
if
(
config
->
hasKey
(
"Schema"
)
)
{
...
...
konsole/SessionManager.h
View file @
e728c533
...
...
@@ -82,7 +82,8 @@ public:
SelectWordCharacters
,
// QString
BlinkingTextEnabled
,
// bool
FlowControlEnabled
,
// bool
AllowProgramsToResizeWindow
// bool
AllowProgramsToResizeWindow
,
// bool
BlinkingCursorEnabled
// bool
};
...
...
konsole/ViewManager.cpp
View file @
e728c533
...
...
@@ -525,6 +525,13 @@ void ViewManager::loadViewSettings(TerminalDisplay* view , Profile* info)
view
->
setScrollBarLocation
(
TerminalDisplay
::
SCROLLBAR_LEFT
);
else
if
(
scrollBarPosition
==
Profile
::
ScrollBarRight
)
view
->
setScrollBarLocation
(
TerminalDisplay
::
SCROLLBAR_RIGHT
);
// terminal features
//bool blinkingText = info->property(Profile::BlinkingTextEnabled).value<bool>();
//TODO - Add a method in TerminalDisplay to allow this to be turned on or off
bool
blinkingCursor
=
info
->
property
(
Profile
::
BlinkingCursorEnabled
).
value
<
bool
>
();
view
->
setBlinkingCursor
(
blinkingCursor
);
}
void
ViewManager
::
profileChanged
(
const
QString
&
key
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment