I decided to work a bit on NppExport, so here it is, 0.2.7.
It sohuld fix the problems with characters outside of the ASCII range (ie, 'eating accented characters'),
aswell as properly export UTF-8 characters.
And the tabs in RTF have been improved, your text should align a bit better in RTF (HTML is still a problem).
Some sort of changelog:
Fix missing characters above 127 (ie 'eating accented characters').
Filters out indicator flags, should prevent out of bounds problems.
HTML uses UTF-8 encoding tag when Scintilla is set to UTF-8.
HTML uses <pre> tag, spaces and tab characters take one space.
HTML uses sc## tag instead of StyleClass## (smaller files).
RTF parses UTF8 data to enable unicode characters.
RTF uses new system for tabstops (better accuracy).
Get the file here:
Would it be possible to also include color mark-up by the Compare Plug-In?
Nope, RTF and HTML cannot render that.
(well HTML maybe but it would have to get extremely advanced, i,m not that good with html).
From ExamDiff Pro's exported HTML Diff Report I know it is possible to also use marker (background) color.
I use pieces of these reports in email, which I can only paste there after copying them from Word after copying and pasting from HTML...
I thought you meant the foreground indicators like that rounded box, I dont know how to do such thing in HTML. The background might be possible, I'd have to look into that (I'd like to avoid stuff like <div> and complex css since that complicates matters quite a bit afaik, although I probably have to use it sometime if I'm going to fix tabs in HTML).
Background colors seem to work for HTML files when exporting to HTML, so that shouldn't be the problem, I guess. I meant background coloring of different lines and inline differences. I didn't even notice the rounded box until now. No, I won't ask you to make a painting of it...
-(the not so HTML expert) Harry
Got it, div is blocklevel and span is inline, I guess I can pull it off with that (only to get the div to be the full width and not the width of the window, which is too short if the horizontal scroll is enabled)
Dear Harry, I've tried the new NPPExport version (0.27). It run fine ! Accented characters are exported perfectly.
Thanks for this good work and for your speed, really !
I put 0.2.7.1 online, RTF has better TAB export (I removed a dirty workaround), and HTML export is now 4.01 strict :P. No real bug fixes though
I'm not getting anything happening when I choose "Copy RTF to Clipboard" (or HTML). Nothing appears on clipboard except the word "RichText" or "HTML". I'm confused :-)
Also v0.2.7.1 is only 13K as opposed to 60K for 0.2.7? Just checking :-)
>I'm not getting anything happening when I choose "Copy RTF to Clipboard" (or HTML). Nothing appears >on clipboard except the word "RichText" or "HTML". I'm confused :-)
Thats not supposed to happen, I dont even put those words there. Have you tried pasting into Wordpad or, if you have it installed (thats how I test it), Thunderbird email composer (not sure about outlook, I ditched that app).
>Also v0.2.7.1 is only 13K as opposed to 60K for 0.2.7? Just checking :-)
No worries, I linked against LIBCTINY which means the DLL gets... tiny (the old one was something like 55) :). This might be the cause of the problems although it shouldnt be. Could you try something like CLCL ( http://www.nakka.com/soft/clcl/index_eng.html )? It can read the clipboard.
Seems it crashes when you export HTML twice, I'll revoke the release untill I can fix it.
Ok, ive uploaded 0.2.7.2, it should fix some issues, hopefully all :).
Could you try it out and see if this time around you actually get something on the clipboard?
Ive tried multiple files and the data seems to stay within memory bounds.
I've downloaded the latest Notepad++ v4.7.5 including NppExport_0_2_7_2_dll.zip as you suggested, but the copy to clipboard function does not work. I've created a file hello.c:
int i = 255;
printf("%i Hello World!\n", i);
Open the file with Notepad++ (the language is set to C). Then click at Plugins -> NppExport -> Copy RTF to clipboard or Copy HTML to clipboard. The result is an empty clipboard. The export to harddisk function works fine.
Do you have a solution for this?
Well, it seems to work fine for me, so that doesnt make it easy :).
Have you tried pasting into Wordpad? Or a clipboard viewer for that matter? I have no idea what could cause this problem.
Do regular clipboard operations work? (should though, the plugin is supposed to warn about problems)
Thanks for your fast reply. I found a solution. I had Notepad++ v4.7.5 installed over an old version without uninstalling it. (I'm using Windows XP SP2) So I've uninstalled it, delete the directory "C:\Documents and Settings\UserName\Application Data\Notepad++" and reinstall the latest v4.7.5 including NppExport.dll from NppExport_0_2_7_2_dll.zip into C:\Program Files\Notepad++\plugins. Now I can copy some formatted code to the clipboard and paste into Wordpad and OpenOffice.org Writer 2.3. Great!
Another question, is it possible to copy HTML formatted code to the clipboard and paste it into Notepad++ itself? The Notepad++ paste button it's grayed out after copying HTML to the clipboard. This is the way I'd like to use NppExport instead of exporting it to a HTML file first.
Thank you very much for your work! I was looking for this feature for long time.
OK Harry, working now.
Amazing difference in dll size.
0.2.7.3 should improve background colors in RTF:
(nothing else changed, so I hope it didnt introduce new bugs)
Perhaps it is a good idea if you (instead of me) start a new thread about NPP Export v 0.2.7.3 being released, allowing to add specific issues to it in its own spot.
Background colors seem to work.
It's not a big problem that only characters get a background, instead of complete lines.
Although some are very light, this is not a problem of the plug-in, but of the configured styles.
I did a comparison using the Compare Plug-In. The comparison colors are not (yet?) copied. I also noticed that one file had (almost) all (or a lot) of black lines, but this could be a problem of the plug-in itself. The other file was colored OK, but these colors I didn't see in my .rtf viewer Wordpad.
I cannot support ComparePlugin, the background color works very differently so to speak :).
Also, I have no clue how to make background colors page width, so its limited to the text only (I doubt RTF has support for it anyway).
As for the threads, well, its a minor release anyway :), and it probably gets included in the next N++ release anyway if its stable.
Black lines? Or blank lines? Blank lines are added by compare plugin
Yes, I know.
No, I have black lines, but this could also be due to my custom color settings. I may have done something wrong. On another computer with default settings it works fine.
<span style="background-color: #FFFFCC">Text on the background</span>