diff options
-rw-r--r-- | HISTORY | 3 | ||||
-rw-r--r-- | displayreplay.c | 7 |
2 files changed, 8 insertions, 2 deletions
@@ -361,4 +361,5 @@ Version 0.1.4 - size of channel logos in main menu timers display configurable as percent of timer width - Added theme dependend background for status icon in displayreplay -- Fixed editing of text if text is scrolling (closes Bug 1572) +- Fixed editing of text if text is scrolling (closes Bug 1572) +- Cutting too long recording name in displayreplay diff --git a/displayreplay.c b/displayreplay.c index c11c543..0f331bb 100644 --- a/displayreplay.c +++ b/displayreplay.c @@ -316,8 +316,13 @@ void cNopacityDisplayReplay::SetRecording(const cRecording *Recording) { void cNopacityDisplayReplay::SetTitle(const char *Title) { pixmapInfo->Fill(clrTransparent); + int titleLength = fontManager->replayHeader->Width(Title); + int titleSpace = geoManager->replayInfoWidth - geoManager->replayHeaderHeight/2; + std::string strTitle = Title; + if (titleLength > titleSpace) + strTitle = CutText(strTitle, titleSpace, fontManager->replayHeader); pixmapInfo->DrawText(cPoint(geoManager->replayHeaderHeight/2, 0), - Title, + strTitle.c_str(), Theme.Color(clrReplayHead), clrTransparent, fontManager->replayHeader); |