Search found 42 matches

by Nobumi Iyanaga
2008-05-19 06:57:44
Forum: Nisus Writer Pro Macros
Topic: Perl output messed up
Replies: 13
Views: 15376

Re: Perl output messed up

Hello Kino, Thank you for your reply. That is not a NW Pro problem but what you always get even from a script run in Terminal, when backticks are used to receive something from an external program. As perl does not know the encoding of the output, the UTF-8 flag is not turned on automatically. I don...
by Nobumi Iyanaga
2008-05-15 17:14:23
Forum: Nisus Writer Pro Macros
Topic: Perl output messed up
Replies: 13
Views: 15376

Hello Martin, Thank you for your reply. This is exactly how embedded perl blocks work. However, it is necessary for the correct functioning of the NWP macro system, which requires that the perl output be encoded using UTF-8. .... Honestly I would consider this a bug in perl. The identity of the char...
by Nobumi Iyanaga
2008-05-14 16:46:56
Forum: Nisus Writer Pro Macros
Topic: Perl output messed up
Replies: 13
Views: 15376


by Nobumi Iyanaga
2008-05-14 04:17:17
Forum: Nisus Writer Pro Macros
Topic: Perl output messed up
Replies: 13
Views: 15376

Perl output messed up

Hello,

I want to write a macro like the following:

Code: Select all

$res = ""
Begin Perl
   $res = `/usr/bin/perl ~/Desktop/myPerlScript.pl`;
End

New
Insert Text $res
If the perl script "~/Desktop/myPerlScript.pl" has a code like the following:

Code: Select all

#!/usr/bin/perl
binmode (STDOUT, ":utf8");
print "あいうえお";
the result will be a mess (something like "ãÂ￾‚ãÂ￾„ãÂ￾†ãÂ￾ˆãÂ￾Š").

Even if I remove the line 'binmode (STDOUT, ":utf8")', I get an even worse result.

How can I get the expected result?

Thank you in advance.
by Nobumi Iyanaga
2008-04-27 15:40:13
Forum: Nisus Writer Pro Macros
Topic: Extract HTML and images from document
Replies: 7
Views: 10098

Hello, I wrote: Related to your script, I think it is still necessary to read the raw rtf code, for instance for grabbing images. But with the new macro, it would be much easier -- or faster to do that. You would do: Find All '^.+', 'E' $doc = Document.active $paragraphs = Array.new $paragraphs = $d...
by Nobumi Iyanaga
2008-04-20 20:41:49
Forum: Nisus Writer Pro Macros
Topic: Extract HTML and images from document
Replies: 7
Views: 10098

Hello Jerry, Related to your script, I think it is still necessary to read the raw rtf code, for instance for grabbing images. But with the new macro, it would be much easier -- or faster to do that. You would do: Find All '^.+', 'E' $doc = Document.active $paragraphs = Array.new $paragraphs = $doc....
by Nobumi Iyanaga
2008-04-19 06:41:56
Forum: Nisus Writer Pro Macros
Topic: converting Classic fonts with non-standard encodings
Replies: 7
Views: 12069

Hello Martin, I tried to write a conversion map for the font "Norman" using your "NSAramian to Unicode.nwm" as template. It seems to work more or less -- I have not yet checked the result very closely. Anyway, I will re-write this macro when you will update the command "transliterateInRange", and th...
by Nobumi Iyanaga
2008-04-18 16:27:04
Forum: Nisus Writer Pro Macros
Topic: converting Classic fonts with non-standard encodings
Replies: 7
Views: 12069

Hello Martin, I am trying to make a mapping table for a transliteration font for East Asian languages, but found a problem: that is, there are many glyphs that can be only obtained using combining characters. For example, U+0072 + U+0325 + U+0304, etc. I think with the new "$text.transliterateInRang...
by Nobumi Iyanaga
2008-04-18 16:03:18
Forum: Nisus Writer Pro Macros
Topic: Extract HTML and images from document
Replies: 7
Views: 10098

Yes, the new macro Attributes object should provide useful. It is however not complete- there is still formatting information that needs to be made available. If there's any particular piece of information you find more critical than another, let us know so we can prioritize it for future enhanceme...
by Nobumi Iyanaga
2008-04-18 00:43:26
Forum: Nisus Writer Pro Macros
Topic: Extract HTML and images from document
Replies: 7
Views: 10098

Hello capvideo, Although I have not yet tried or understood your scripts, I am very impressed by them. They seem really very good. I will try them, and try to study them. You write in your web page: it’d be a whole lot nicer (and likely more reliable) if I could get the style names directly from Nis...
by Nobumi Iyanaga
2008-04-17 23:33:29
Forum: Nisus Writer Pro Macros
Topic: converting Classic fonts with non-standard encodings
Replies: 7
Views: 12069

Hello Martin, This is a very good idea! I worked a lot in this area. See my web page "East Asian Diacritical Fonts and Unicode" http://www.bekkoame.ne.jp/~n-iyanag/researchTools/diacriticalfontsandunicode.html and "Classic Nisus Writer to Nisus Writer Express/Pro" http://www.bekkoame.ne.jp/~n-iyanag...
by Nobumi Iyanaga
2008-04-15 06:30:07
Forum: Nisus Writer Pro
Topic: Convert many files
Replies: 8
Views: 7735

Re: batch conversion

Hello igroucho, I have loads of Nisus files saved from a mac belonging once to my passed away father. All dating back as early as 91-92. I'd like from various reasons, among all pc-comp, to convert them to MsWord files. When I open a file in Nisus it's opened as "Untitled" but I'd like NW to retain ...