File Window Tip - linebreaks in description

Started by JohnZeman, June 18, 2022, 05:13:38 PM

Previous topic - Next topic


I know I did this once several years ago but I can't remember how.  :o

In a file window tip configuration how do I insert linebreaks in the description so a file window tip description looks the same as a metadata layout description?

I thought


Should work but it doesn't seem to do anything.  What am I missing?
Thanks in advance.


pereplace:This==That does the trick:


The default File Window tip does this for the description:

{File.MD.XMP::dc\description\Description\0|pereplace:{cr}{lf}==</Run><LineBreak/><Run Foreground="#ffaa00" FontSize="8pt">;prefix:<Run Foreground="#ffaa00" FontSize="8pt">;postfix:</Run>}

You can load the default tip from C:\ProgramData\\IMatch6\Presets\system-high-res.imfwt


Thanks Mario, I had tried pereplace before posting this thread and it didn't work.  I just loaded your default file window tip and it doesn't replace line breaks either.

I've attached a file window tip screenshot with your default C:\ProgramData\\IMatch6\Presets\system-high-res.imfwt loaded.

Bug maybe?


It does.
Are you sure your data contains CRLF or maybe just LF? I've just <Shift>+<Enter> to add line breaks.

Also, the extra blank lines between the paragraphs are a "not a concept" for XAML rendering. They will be folded unless you produce actual text blocks with margins or padding from your content.


This is so strange.  If I edit a description in my metadata layout and manually insert extra linebreaks there by using SHIFT+ENTER the file window tip does not show the added linebreaks in the description.

But if I copy the description to my favorite text editor NoteTab Pro and add the line breaks there then copy and paste the description back into the iMatch metadata layout description field, then the file window tip does display the line breaks.

Now I just tried adding extra linebreaks again using the Metadata Lyout editor and this time the file window tip does show the line breaks.

I don't know what's going on Mario I'll keep trying to pin this down to something specific.


Note: The File Window tip may have some data cached. Open the tip on another file and then go back to the file you have just modified to force the cache to clear.

Both <Ctrl>+<Enter> and <Shift>+<Enter> in the MD panel should work and add line breaks.


That helps Mario, thanks again.

If I select one image without doing anything to it linebreaks are not shown.  If I make a tiny change to that description then writeback metadata it still doesn't show linebreaks.

But if I select a different image then come back to the first one, linebreaks are shown.

I wonder if I'm the only one who has this problem?


Your editing of linebreaks may interfere with the File Window caching the File Window tip.
Not sure if this is to be considered a bug. Maybe open a bug report and I will look into this for one of the next releases.
Not many users use File Window tips or at least don't use them at the same time the actively modify metadata in the MD panel.
Monitoring the MD panel may harm File Window tip and/or File Window performance - the cache is there for a reason. Opening the FWT for another image after you have editing an image and then the FWT for the edited image will always show the up-to-date tip.


I think I'll wait and see if anyone else has the same issue.  If they do I'll submit a bug report, otherwise I'll assume it's something on my end.

Thanks again Mario


I have upgraded this to a bug and fixed it for the next release.