ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > FARR Plugins and Aliases

Locate32 Plugin for FARR by Okke

<< < (16/25) > >>

f0dder:
Yes, as PlatformSDK states, WriteConsole will fail when used with redirection... so that's no good. If you redirect file, GetStdHandle() returns a file handle, so things should work fine. I think/hope notepad fails because the file lacks a BOM marker, but I'll do some testing, also of the code from the blog...

At the plugin side, I guess it comes down to whether you want to parse utf-8 or use ucs-16 directly. For locate, it's probably some printf calls that need to be changed to more specific code.

jmj:
Ok, it seems that unicode characters do not work even in console. It worked when I tested before, but probable
used copepage was valid for those charactes (those was cyrillic or chinese alphapets, now I tested random characters).


So what all I should do to get it work like you want? Atm locate.exe uses wprintf

f0dder:
Ok, it seems that unicode characters do not work even in console. It worked when I tested before, but probable
used copepage was valid for those charactes (those was cyrillic or chinese alphapets, now I tested random characters).
-jmj (December 29, 2007, 03:17 AM)
--- End quote ---
Hm, it did work for my test, but all I used was some russian text. I did have to choose a non-raster font for the console, though. My codepage is 850, I doubt cyrillic characters are valid in that codepage?

So what all I should do to get it work like you want? Atm locate.exe uses wprintf
-jmj (December 29, 2007, 03:17 AM)
--- End quote ---
I guess we should take a look at the CRT implementation of wprinf (source comes with visual studio) and see how they handle it... but it breaks down to using WriteConsoleW for consoles, and WriteFile (possibly with wide->multibyte translation) for redirected stdout. If VS CRT doesn't do it this way, it means writing your own little printf. But since it's only really necessary for printing out the file paths, you can do without formatting specifiers etc.

Perhaps I ought to access the repository and actually DO something :)

jmj:
It's not necessary to use wsprintf, until it's something which works.

You can try to fix it if you wish. If you haven't noticed, new address for the repository is http://svn.locate32.net/locate32. The repository can be read by anyone and your old password should work for writing.

Armando:
Armando: I'm using locate 3.0 build 7.12260, from the x64 build.
-f0dder (December 27, 2007, 06:33 PM)
--- End quote ---

Thanks. so you in the x64 world...

So where does the cure for diacritics lies ?  :)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version