mirror of
https://github.com/vdr-projects/vdr.git
synced 2025-03-01 10:50:46 +00:00
Fixed truncated date/time strings in the skins on multi-byte UTF-8 systems
This commit is contained in:
@@ -135,3 +135,5 @@ VDR Plugin 'skincurses' Revision History
|
||||
|
||||
- Added cFont::Width(void) to get the default character width and allow stretched
|
||||
font drawing in high level OSDs (dummy for skincurses).
|
||||
- Fixed truncated date/time strings in the skins on multi-byte UTF-8 systems
|
||||
(reported by Sergey Chernyavskiy).
|
||||
|
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: skincurses.c 4.1 2016/12/22 12:50:20 kls Exp $
|
||||
* $Id: skincurses.c 4.2 2016/12/22 14:09:09 kls Exp $
|
||||
*/
|
||||
|
||||
#include <ncurses.h>
|
||||
@@ -408,8 +408,7 @@ void cSkinCursesDisplayMenu::SetEvent(const cEvent *Event)
|
||||
return;
|
||||
int y = 2;
|
||||
cTextScroller ts;
|
||||
char t[32];
|
||||
snprintf(t, sizeof(t), "%s %s - %s", *Event->GetDateString(), *Event->GetTimeString(), *Event->GetEndTimeString());
|
||||
cString t = cString::sprintf("%s %s - %s", *Event->GetDateString(), *Event->GetTimeString(), *Event->GetEndTimeString());
|
||||
ts.Set(osd, 0, y, ScOsdWidth, ScOsdHeight - y - 2, t, &Font, clrYellow, clrBackground);
|
||||
if (Event->Vps() && Event->Vps() != Event->StartTime()) {
|
||||
cString buffer = cString::sprintf(" VPS: %s", *Event->GetVpsString());
|
||||
|
Reference in New Issue
Block a user