Page 1 of 1

Newline in Timestamp and %Q

Posted: Thu Mar 05, 2020 8:57 pm
by chibi
In my system I am using ZMTrigger and the %Q option for Timestamp and would like to insert a newline before the external data provided by %Q.
Using a Timestamp string of:
%N - %d/%m/%y %H:%M:%S %Q
Then using telnet:
1|show||||testingOSD
for example.
This shows the name, date, time, and external data [testingOSD] on one line.

There have been some references to using \n for a newline in the Timestamp for Zoneminder. Specifically in release notes;
Release 1.22.3 - 2006/11/23 FEATURE : The timestamp displayed on images can now contain newlines. Use the \n (a ‘slash’ followed by an ‘n’) to represent that.
For me, using %n works instead of \n to insert a newline in the display and text following the newline works; however, the %Q does not anymore. In fact; it appears that since getting a newline to work, %Q no longer works at all, on any monitor. After restarting Zoneminder without any %n in the Timestamp string, the %Q functionality returns.

Has anyone else noticed this behavior and found a workaround for it?

Re: Newline in Timestamp and %Q

Posted: Fri Mar 06, 2020 12:01 am
by iconnor
We probably use a regexp that matches a single line. I can probably fix that. Might go into 1.34.6 more likely 1.34.7

Re: Newline in Timestamp and %Q

Posted: Wed Mar 11, 2020 7:31 pm
by chibi
Can wait for 1.35.x version. :D