Plugin:HistoryPP/en/Text formatting

From Miranda NG
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

The following STRING keys are used to change text which is copied to clipboard.

Key Default Description
FormatCopy %nick%, %smart_datetime%:\n%mes%\n Formats text which is copied to clipboard on Copy command
FormatCopyText %mes%\n Formats text which is copied to clipboard on Copy Text command
FormatReplyQuoted %nick%, %smart_datetime%:\n%quot_mes%\n Formats text which is copied to message input area on Reply Quoted command
FormatReplyQuotedText %quot_selmes%\n Formats selected text which is copied to message input area on Reply Quoted command
FormatSelection %selmes%\n Formats selected messages or text via external log API query

You will need Database Editor plugin to add/edit these keys. To restore default format for particular setting, just delete it from the database and restart Miranda.


Formatting variables

Variable Description
\n New line
\t Tab
\\ Backslash (if you need to output backslash, instead of "Me\You" write "Me\\You")
\% Percent sign (if you need to output percent sign, instead of "Me%You" write "Me\%You")
%nick% Default contact's nickname text
%from_nick% Nick of the sender
%to_nick% Nick of the reciever
%mes% Plain message text
%adj_mes% Message adjusted to fit in 72 symbols
%quot_mes% The same as %adj_mes%, but every line is prefixed with "> "
%selmes% The same as %mes% or selected text in pseudo-edit mode
%adj_selmes% The same as %adj_mes% or applied to selected text in pseudo-edit mode
%quot_selmes% The same as %quot_mes% or applied to selected text in pseudo-edit mode
%datetime% Date and time of the event
%smart_datetime% Works only for several messages. Outputs full date & time only for messages with unique date. For other events outputs only time.
%date% Date of the event
%time% Time of the event


Single event examples

Event:

SomeContact, 21.01.2006 18:34
Hello, how are you? I haven't seen you for a long time. I've got fantastic new gadget I want to tell you about. Please, drop me a line.

Format: %nick% - [%datetime%]:\n%mes%

SomeContact - [21.01.2006 18:34]:
Hello, how are you? I haven't seen you for a long time. I've got fantastic new gadget I want to tell you about. Please, drop me a line.

Format: %nick%, %time%\n%quot_mes%

SomeContact, 18:34
> Hello, how are you? I haven't seen you for a long time. I've got fantastic
> new gadget I want to tell you about. Please, drop me a line.


Multiple events examples

Events:

Mario, 21.01.2006 18:34: Hi!
You, 21.01.2006 18:35: Hi!
Mario, 21.01.2006 18:36: Bye then
You, 22.01.2006 12:11: Hi again! Where have you been?
Mario, 22.01.2006 12:12: Oh, don't ask

Format: %nick%, %smart_datetime%: %quot_mes%

Mario, 21.01.2006 18:34: > Hi!
You, 18:35: > Hi!
Mario, 18:36: > Bye then
You, 22.01.2006 12:11: > Hi again! Where have you been?
Mario, 12:12: > Oh, don't ask

Format: %from_nick%\\%to_nick% [%smart_datetime%]: %mes%\n-----\n

Mario\You [21.01.2006 18:34]: Hi!
-----
You\Mario [18:35]: Hi!
-----
Mario\You [18:36]: Bye then
-----
You\Mario [22.01.2006 12:11]: Hi again! Where have you been?
-----
Mario\You [12:12]: Oh, don't ask
-----

Format: %nick%\t[%time%]\t%mes%

Mario	[18:34] Hi!
You	[18:35] Hi!
Mario	[18:36] Bye then
You	[12:11] Hi again! Where have you been?
Mario	[12:12] Oh, don't ask


See also