Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] Show unread count in terminal window title
@ 2011-04-29 10:59 Alexander Shulgin
  2011-04-30 13:04 ` Alexander Shulgin
  0 siblings, 1 reply; 2+ messages in thread
From: Alexander Shulgin @ 2011-04-29 10:59 UTC (permalink / raw)
  To: sup-talk

Hello fellow sup users,

I'd like sup to display the count of unread messages in the terminal
window's titlebar like this: "Sup 0.11 :: Inbox (1)".  Currently it
only displays "Sup 0.11 :: Inbox".

I've tried searching this list archives, but it appears nobody asked
for this before, and since the issue tracker is down I can't tell if
there's such a feature request already.

Any suggestions?  Should I ask on the -devel list instead?

--
Alex
PS: I'm proficient in Ruby, but didn't try to read any of the sup code yet.
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [sup-talk] Show unread count in terminal window title
  2011-04-29 10:59 [sup-talk] Show unread count in terminal window title Alexander Shulgin
@ 2011-04-30 13:04 ` Alexander Shulgin
  0 siblings, 0 replies; 2+ messages in thread
From: Alexander Shulgin @ 2011-04-30 13:04 UTC (permalink / raw)
  To: sup-talk

On Fri, Apr 29, 2011 at 13:59, Alexander Shulgin <alex.shulgin@gmail.com> wrote:
> Hello fellow sup users,
>
> I'd like sup to display the count of unread messages in the terminal
> window's titlebar like this: "Sup 0.11 :: Inbox (1)".  Currently it
> only displays "Sup 0.11 :: Inbox".

And here's what I could find.  There's a hook to set the window title,
called .sup/hooks/terminal-title-text.rb.  I can get close to what I
want with this:

("Sup 0.11 :: #{title}" + (num_inbox_unread > 0 ?
"(#{num_inbox_unread})" : "")) if mode == "inbox-mode"

However, I'd like to avoid hard-coding the "Sup #{version_here}" part,
or at least use some variable.  Also, there's a bug with manually
changing (un)read status of a thread: the unread count first goes to
1, and only on next keystroke it's updated to reflect that the whole
thread's unread.  The same is when marking a whole thread read...

--
Alex
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-04-30 14:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-29 10:59 [sup-talk] Show unread count in terminal window title Alexander Shulgin
2011-04-30 13:04 ` Alexander Shulgin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox