wstring ws(L"Press 'q' to end.");
wcout << ws;
error C2679: binary '<<' : no operator
found which takes a right-hand operand
of type 'std::wstring' (or there is no
acceptable conversion)
This is in a VC++ 2005 Win32 console app, created with default settings... which I think means UNICODE is on? I only just found out cout do...
I am trying to print unicode in a JTextArea. I have gotten it to print fine to the console but when I try to print it to the textarea, I get boxes for all of the two byte unicode characters. Any help would be much appreciated.
package edu.afit.jieddo;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class JTe...
I am trying to get unicode working on windows in a visual studio 2k8 project, and I am not sure why I can't get my project to work. My machine has all the Eastern language support installed. I went to properties->project defaults->character set: and it is set to "Use Unicode Character Set". Here is my test code:
#include <stdio.h>
#incl...
I have a scraper that is collecting some data from elsewhere that I have no control over. The source data does all sorts of interesting Unicode characters but it converts them to a pretty unhelpful format, so
\u00e4
for a small 'a' with umlaut (sans the double quotes that I think are supposed to be there)*. of course this gets render...
I'm slightly confused and hoping for enlightenment.
I'm using Delphi 2010 for this project and I'm trying to compare 2 strings.
Using the code below fails
if AnsiStrIComp(PAnsiChar(sCatName), PAnsiChar(CatNode.CatName)) = 0 then...
because according to the debugger only the first character of each string is being compared.
I.E. if s...
I have a MySQL table where I store text entered in any kind of language. The text is displayed correctly on the website, example but when I export the data to Excel I get garbled text.
I tried exporting the data via PHPMyAdmin and even just doing something from the command line like mysql -user -p db < query.sql > export.tsv and I get...
I am working with a class that wraps the std::wstring, this code needs to be cross platform, are there equivalents to the windows functions: MultiByteToWideChar & WideCharToMultiByte on linux?
Thank you.
...
I'm working with unicode/wide characters and I'm trying to create a toString method (Java ::toString equiv). Will ostream handle wide characters, if so is there a way to warn the consumer of the stream that it is unicode coming out of it?
...
I am developing an NSIS installer for a product that has a superscript in its name. Is it possible to encode superscript text in the installer script?
In particular, I'd like to get the Name, BrandingText and Caption to display the superscript.
I would be willing to switch to the NSIS Unicode build if that would definitively solve t...
I'm working on a series of parsers where I get a bunch of tracebacks from my unit tests like:
File "c:\Python31\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 112: character maps to <undefined>
T...
Hi,
I am having problems with the DictWriter and non-ascii characters. A short version of my problem:
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import codecs
import csv
f = codecs.open("test.csv", 'w', 'utf-8')
writer = csv.DictWriter(f, ['field1'], delimiter='\t')
writer.writerow({'field1':u'å'.encode('utf-8')})
f.close()
Giv...
I want to implement my own tweet compressor. Basically this does the following. However I'm stuck with some of the unicode issues.
Here's my script:
#!/usr/bin/env perl
use warnings;
use strict;
print tweet_compress('cc ms ns ps in ls fi fl ffl ffi iv ix vi oy ii xi nj/, "\. " ,", "'),"\n";
sub tweet_compress {
my $tweet = shif...
Hello,
I want to type some letters in GMAIL but it shows me boxes on my pc
instead of showing correct letters. I have MAC 10.5.5. I have tried in
Safari & firefox but same issue. Its working fine on windows. So
please let me know whats issue with MAC.
Thanks in advance,
Laxmilal Menaria
...
Hello everyone,
I have created a sample Indian site and tried in Safari on MAC 10.5.5, I am unable to view, Browser shows Boxes instead of valid text.
I tried the same on latest firefox browser but same issue. I have changed the encoding to UTF-8 in browser preferences but it not help.
Please let me know how to resolve this.
Thanks i...
I'm working with an SQL Server 2005 Express instance. Any attempt (both programatically or by using a table editor (for example VS Server Explorer --> Edit Table Data)) to enter a unicode string results in a sequence of question marks (????). I guess that either SQL Server 2005 Express doesn't support unicode at all or it requires some e...
Consider this program:
#include <stdio.h>
int main() {
printf("%s\n", __FILE__);
return 0;
}
Depending on the name of the file, this program works - or not. The issue I'm facing is that I'd like to print the name of the current file in an encoding-safe way. However, in case the file has funny characters which cannot be represe...
I wanted to url encode a python string and got exceptions with hebrew strings.
I couldn't fix it and started doing some guess oriented programming.
Finally, doing mystr = mystr.encode("utf8") before sending it to the url encoder saved the day.
Can somebody explain what happened? What does .encode("utf8") do? My original string was a un...
Hi,
I am using Python 2.6.1 and am having utf-8 related problem with my code. This problem is reproducible with this code:
# -*- coding: utf-8 -*-
import os, sys
import string, time
import codecs, re
bDATA='"Domenick Lombardozzi","Eddie Marsan","Isaach De Bankolé","John Hawkes"'
print (bDATA)
fileObj = codecs.open("btvresp1.txt", "r", ...
I am reading about the charater set and encodings on Windows. I noticed that there are two compiler flags in Visual Studio compiler (for C++) called MBCS and UNICODE. What is the difference between them ? What I am not getting is how UTF-8 is conceptually different from a MBCS encoding ? Also, I found the following quote in MSDN:
Uni...
My application needs to be I18N compliant. One of the requirements is that the initial password I generate should be in the User's chosen language. What API in Java can I use to achieve this? I have the user's language and will need to get a few random characters from the unicode set of that language.
Edit: Thank you for the answers so ...