Ticket #824 (closed enhancement: fixed)

Opened 16 months ago

Last modified 4 months ago

add WindowTitle shadow tiddler to define document's browser window title text

Reported by: EricShulman Owned by: MartinBudden
Priority: minor Milestone: 2.6
Component: core Version:
Severity: low Keywords:
Cc:

Description (last modified by EricShulman) (diff)

Currently, the browser window's title text is set using a combination of the contents from SiteTitle? and SiteSubtitle?.

In addition to appearing in the titlebar, the browser window's title text is also displayed when the browser is minimized to the system's "task bar" (or other similar interface showing the running applications), and is also used when creating a bookmark for the URL.

This enhancement will allow document authors to specify custom text that will appear in the browser window's title bar, in place of the default combination of SiteTitle? and SiteSubtitle?.

Based on a suggestion from Jeremy, the following code defines a new shadow tiddler, WindowTitle?, and instead of using hard-coded formatting in getPageTitle(), it renders the WindowTitle? content as plain text to set the actual window title text. It also adds a notification so that the window title will be kept in sync when a custom WindowTitle? tiddler is created/modified.

config.shadowTiddlers.WindowTitle="<<tiddler SiteTitle>> - <<tiddler SiteSubtitle>>";
window.getPageTitle=function() { return wikifyPlain("WindowTitle"); }
store.addNotification("WindowTitle",refreshPageTitle);

This code has been successfully implemented at  http://www.TiddlyTools.com/#CoreTweaks##824

see also  http://trac.tiddlywiki.org/ticket/401 (closed)

Change History

Changed 16 months ago by EricShulman

  • priority changed from undefined to minor
  • severity changed from undefined to low
  • type changed from defect to enhancement
  • description modified (diff)
  • milestone set to 2.5

Changed 14 months ago by MartinBudden

  • owner changed from JeremyRuston to EricShulman

Changed 12 months ago by FND

On the one hand, I really like this. On the other hand, I worry about adding yet another shadow tiddler to the core.

Given that I expect most people not to make use of this (a debatable assumption), this might better be implemented as a plugin.

Changed 12 months ago by MartinBudden

  • milestone changed from 2.5.1 to 2.5.2

Changed 8 months ago by FND

  • milestone changed from 2.5.3 to 2.5.4

Changed 4 months ago by MartinBudden

  • owner changed from EricShulman to MartinBudden

Changed 4 months ago by MartinBudden

  • status changed from new to closed
  • resolution set to fixed

Fixed in changeset:11274

Note: See TracTickets for help on using tickets.