Update on Controlling Konsole via DBUS
Recently I wrote about controlling konsole with dbus. As I've begun to use that script for setting up my konsoles I, like others, have discovered that the tab title that you set with dbus doesn't stick. This short note shows you a workaround to make your tab titles stay put.
Even though I wrote the original post a few weeks back I didn't realize that I had a problem until now because I just this weekend upgraded the system that I use most often. Plus, apparently, I already discovered the workaround on my other system and proceeded to immediately forget about it as it took me a fair amount of fiddling to figure it out (again) today.
Before I actually (re)-discovered the workaround I did a bit of looking through the konsole code and noticed that konsole has two types of tab titles: one that's set with the function setTitle() and another that's set with the function setUserTitle(). If you don't set the one that's set with setUserTitle() then the tab title changes back to the default when you use the session. The problem is that the dbus interface allows you to call setTitle() but it does not allow you to call setUserTitle().
You can invoke setUserTitle() using konsole's menu via: Edit->Rename Tab or from the keyboard with Ctrl-Alt-S. If you set the (user) title that way you'll see that it now sticks. But that's not the workaround, since we're trying to control konsole via dbus going through and manually setting all the tab titles via the keyboard or mouse doesn't constitute a workaround.
The actual workaround on the other hand isn't without its flaws either: it requires you to change the shell profile, which means that since starting a session with a specified profile via dbus doesn't work yet, you can't have both behaviors at the same time.
After that long-winded prolog, the workaround is quite simple: using konsole's menu do: Settings->Edit Current Profile..., go to the Tabs tab and clear both the Tab title format and the Remote tab title format fields.
This works because konsole doesn't reset the tab title if there is no default value to set it to.
| Attachment | Size |
|---|---|
| editprofile2.jpg | 60.97 KB |
Mitch Frazier is an Associate Editor for Linux Journal.
Trending Topics
| Dia - The Diagram Creation Tool | Feb 13, 2012 |
| You Need A Budget | Feb 10, 2012 |
| The Linux powered LAN Gaming House | Feb 08, 2012 |
| Creating a vDSO: the Colonel's Other Chicken | Feb 06, 2012 |
| Your CMS Is Not Your Web Site | Feb 01, 2012 |
| Casper, the Friendly (and Persistent) Ghost | Jan 31, 2012 |
- Fun with ethtool
- Linux--The Internet Appliance?
- Dia - The Diagram Creation Tool
- Readers' Choice Awards 2011
- Validate an E-Mail Address with PHP, the Right Way
- Stack Backtracing Inside Your Program
- Python for Android
- LiS: Linux STREAMS
- Building a Two-Node Linux Cluster with Heartbeat
- Three-Tier Architecture
- Dia
4 hours 29 min ago - Service units, is a daemon
6 hours 4 min ago - Tcp
6 hours 24 min ago - Lamenting more development of Dia
12 hours 16 min ago - multiboot that works well for me
22 hours 7 min ago - What's a good, AFFORDABLE aka
22 hours 8 min ago - Employment Posters
1 day 13 hours ago - Sure the best distro is
1 day 14 hours ago - BeOS was the best
1 day 17 hours ago - I use Wireshark on a daily
1 day 22 hours ago





Comments
Why don't you report it as a
Why don't you report it as a bug to DBus developers? Get them to fix it and none of us have to deal with work-arounds.