ALT Linux Sisyphus discussions
 help / color / mirror / Atom feed
From: "Anton V. Boyarshinov" <boyarsh@ru.echo.fr>
To: sisyphus@altlinux.ru
Subject: [sisyphus] Re: qcad && lyx-qt (was licq)
Date: Thu, 17 Apr 2003 13:43:48 +0400
Message-ID: <20030417093655.484002B51B@mail.ru.echo.fr> (raw)
In-Reply-To: <200304171320.03320.zerg@altlinux.ru>

On Thu, 17 Apr 2003 13:19:58 +0400 Sergey V Turchin
 wrote:

> >  wrote:
> > > > Конкретно: QFileDialog возвращает строку с путём к файлу.
> > > > Я её вывожу с помощью printf и вижу ???? вместо русских
> > > > букв.
> > >
> > > Потому, что это юникод.
> > > В локали ru_RU.UTF-8 Вы увидели бы русские буквы
> >
> > ПОстойте, постойте, в локали koi8-r, если выводить utf-8 при
> > помощи printf. должно выглядеть примерно так:
> >  echo "привет" | iconv -f koi8-r -t utf-8
> > п©я─п╦п╡п╣я┌
> Зато в этом варианте количество символов не такое,
> как на самом деле в этой строке.

Зато количество байтов такое ;)

> Да смысл не в этом. В программе стоит
> fopen(QString, const char)
> а нужно
> fopen(QString->local8Bit()->data(), const char)

Возможно, но вывод ??? при printf это отнюдь не объясняет. printf
не знает о символах, а тупо выводит по байтам.
 
> > > > Как выглядит UTF-8, я знаю - совсем не так.
> > > В koi8-r их нет, поэтому они никак не выглядят ;-)
> >
> > Очень даже выглядят. И совсем не в виде ????
> Это выглядят не они, а то, во что они превратились :)

Это не важно. В любом случае, при выводе utf-8 при помощи printf
занки вопроса образовываться не должны.

Антон
-- 
mailto:boyarsh@mail.ru
mailto:boyarsh@ru.echo.fr
 13:40:01  up 42 days, 20:08, 10 users,  load average: 0.16,
0.07, 0.14


  reply	other threads:[~2003-04-17  9:43 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-15  9:06 [sisyphus] licq Andriy Dobrovol's'kii
2003-04-15 15:33 ` Sergey V Turchin
2003-04-16  7:10   ` Andriy Dobrovol's'kii
2003-04-16  9:03     ` Sergey V Turchin
2003-04-16  9:23       ` Andriy Dobrovol's'kii
2003-04-16 10:40         ` Sergey V Turchin
2003-04-16 14:26           ` Vitaly Lipatov
2003-04-16 15:26             ` Sergey V Turchin
2003-04-16 17:21               ` Vitaly Lipatov
2003-04-16 17:50                 ` [sisyphus] qcad && lyx-qt (was licq) Sergey V Turchin
2003-04-16 19:24                   ` Vitaly Lipatov
2003-04-17  7:38                     ` Sergey V Turchin
2003-04-17  8:31                       ` [sisyphus] " Anton V. Boyarshinov
2003-04-17  9:19                         ` Sergey V Turchin
2003-04-17  9:43                           ` Anton V. Boyarshinov [this message]
2003-04-17  9:56                             ` Sergey V Turchin
2003-04-17 21:59                               ` Vitaly Lipatov
2003-04-18 11:05                                 ` Sergey V Turchin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030417093655.484002B51B@mail.ru.echo.fr \
    --to=boyarsh@ru.echo.fr \
    --cc=sisyphus@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Sisyphus discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
		sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
	public-inbox-index sisyphus

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.sisyphus


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git