mIRC Home    About    Download    Register    News    Help

Print Thread
Unicode in debugging windows #230153 26/02/11 05:02 PM
Joined: Feb 2011
Posts: 3
N
NTVgog Offline OP
Self-satisified door
OP Offline
Self-satisified door
N
Joined: Feb 2011
Posts: 3
Hello,

When I enable the mIRC debugging windows, and then paste any unicode characters in any chat window, such as ěčřůťňď (visible depending on your browser's unicode support and correct font) then those special characters are not rendered properly in the debugging window. I have confirmed this issue with other people.

Re: Unicode in debugging windows [Re: NTVgog] #230159 26/02/11 10:12 PM
Joined: Apr 2010
Posts: 939
F
FroggieDaFrog Offline
Hoopy frood
Offline
Hoopy frood
F
Joined: Apr 2010
Posts: 939
are they showing up as rectangles because it might be the font you are using doesn't support the characters you are trying to display.

Personally I recommend the DejaVu set.

I am presuming you are using something similar to /debug @raw so after creating the window, try using /font @raw <fontsize> <fontname> to see if the outcome changes smile





I am SReject
My Stuff
Re: Unicode in debugging windows [Re: FroggieDaFrog] #230160 26/02/11 10:31 PM
Joined: Feb 2011
Posts: 3
N
NTVgog Offline OP
Self-satisified door
OP Offline
Self-satisified door
N
Joined: Feb 2011
Posts: 3
I am using the same font I am using in the chat window - the chat windows shows the characters correctly. It is only the debugging window.

The debug window does not show rectangles (or any other substitute character) it just shows plain wrong characters. Just try it yourself: &#283;&#269;&#345;&#367;&#357;&#328;&#271; put those things in the chat window - they will display correctly, but will display wrongly in debug window.

The only thing that comes to my mind as an explanation for this behavior is that the debug window splits the 2-byte characters (the ones which are unicode and not mapped to ANSI or ASCII) into 2 1-byte characters.

Re: Unicode in debugging windows [Re: NTVgog] #230161 26/02/11 10:36 PM
Joined: Sep 2005
Posts: 2,878
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,878
Confirmed.

Re: Unicode in debugging windows [Re: NTVgog] #230162 26/02/11 10:44 PM
Joined: Apr 2010
Posts: 939
F
FroggieDaFrog Offline
Hoopy frood
Offline
Hoopy frood
F
Joined: Apr 2010
Posts: 939
Yup, confirmed with 7.18 beta

Just Help Khaled out, the debug window text looks like:
Quote:
&#155;šč&#153;žýáíéúůť&#136;

Last edited by FroggieDaFrog; 26/02/11 10:49 PM.

I am SReject
My Stuff
Re: Unicode in debugging windows [Re: NTVgog] #230164 27/02/11 12:10 AM
Joined: Apr 2004
Posts: 846
Sat Offline
Hoopy frood
Offline
Hoopy frood
Joined: Apr 2004
Posts: 846
This is by design.

Originally Posted By: versions.txt
17/02/2006 - mIRC v6.17

44./debug windows now show raw text without interpreting multibyte or utf text.


Saturn, QuakeNet staff
Re: Unicode in debugging windows [Re: NTVgog] #230171 27/02/11 04:05 AM
Joined: Feb 2006
Posts: 546
J
jaytea Offline
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2006
Posts: 546
there is a simple way for you to view Unicode in your debug window or file. when enabling debug mode, use the following line:

Code:
/debug -i @debug utfdecode


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde
Re: Unicode in debugging windows [Re: jaytea] #230172 27/02/11 07:18 AM
Joined: Jul 2007
Posts: 1,129
T
Tomao Offline
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
Is't it
Quote:
$utfdecode()
The dollar sign and string are missing. Or was it done that way on purpose?

Re: Unicode in debugging windows [Re: Tomao] #230173 27/02/11 07:51 AM
Joined: Oct 2003
Posts: 3,918
A
argv0 Offline
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
It was on purpose. Perhaps you should try commands before attempting to correct them.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Re: Unicode in debugging windows [Re: argv0] #230174 27/02/11 08:24 AM
Joined: Jul 2007
Posts: 1,129
T
Tomao Offline
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
Originally Posted By: argv0
Perhaps you should try commands before attempting to correct them.
I wasn't sure, and I wasn't "attempting" to "correct," just showing it in a colored highlight in question so I can be given an answer to it. You didn't have to sound discourteously harsh to put me in a tight spot. Just because you know, doesn't mean other people do.

Re: Unicode in debugging windows [Re: Tomao] #230175 27/02/11 08:26 AM
Joined: Feb 2006
Posts: 546
J
jaytea Offline
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2006
Posts: 546
as with /filter -k, mIRC takes the <alias> argument you've supplied to /debug (which incidentally, unlike in /filter, may contain spaces), encloses it in '$' and '($1-)' and evaluates the result.

with this:

Code:
/debug -i @win utfdecode


mIRC evaluates $utfdecode($1-), which is acceptable.

with this:

Code:
/debug -i @win $utfdecode()


mIRC evaluates $$utfdecode()($1-), which is not acceptable, as it always evaluates to $null.


"The only excuse for making a useless script is that one admires it intensely" - Oscar Wilde
Re: Unicode in debugging windows [Re: jaytea] #230176 27/02/11 08:41 AM
Joined: Jul 2007
Posts: 1,129
T
Tomao Offline
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
Thank you very much, jaytea. I appreciate your taking the time for the explanation.

Re: Unicode in debugging windows [Re: NTVgog] #230177 27/02/11 10:17 AM
Joined: Feb 2011
Posts: 3
N
NTVgog Offline OP
Self-satisified door
OP Offline
Self-satisified door
N
Joined: Feb 2011
Posts: 3
I can confirm that the following code:

Code:
/debug -i @debug utfdecode


solves my issue. Thank you.