Rank: Member
Groups: Guest
Joined: 5/31/2006(UTC) Posts: 20
|
hi, i need to fraw cyrillic characters with youre library. This is my code: Code:
using (Aurigma.GraphicsMill.Drawing.GdiGraphics g = txtbmp.GetGdiGraphics())
{
Aurigma.GraphicsMill.Drawing.Font theFont = new Aurigma.GraphicsMill.Drawing.Font(
"Arial",
8,
false,
false,
300,
300);
TheFont.Unit = Aurigma.GraphicsMill.Unit.Point;
theFont.Antialiased = true;
using (Aurigma.GraphicsMill.Bitmap txtbmp = new Aurigma.GraphicsMill.Bitmap())
{
txtbmp.Create(theSize.Width, theSize.Height, Aurigma.GraphicsMill.PixelFormat.Format1bppIndexed);
using (Aurigma.GraphicsMill.Drawing.GdiGraphics g = txtbmp.GetGdiGraphics())
{
g.Clear(Aurigma.GraphicsMill.RgbColor.Transparent);
}
g.DrawString(
theText,
theFont,
new Aurigma.GraphicsMill.Drawing.SolidBrush(Aurigma.GraphicsMill.RgbColor.Black),
0,
0);
}
}
A test showed, that the DrawString(..) Function draws cyrillic characters that need 7 bit. If there is a character, that needs 8 bit (1byte), the function doesn't draw the character. Can you help please. best regards Christian Büttner Edited by user Monday, December 17, 2007 12:52:07 PM(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member
Groups: Guest
Joined: 1/31/2005(UTC) Posts: 458
Was thanked: 5 time(s) in 5 post(s)
|
Hello Christian, I tried to reproduce this error on my machine but without any result. Here is my code (it is based on yours, but I removed some parts which I don't understand. E.g. first "using" clause which do nothing and which looks very suspicious): Code:Aurigma.GraphicsMill.Bitmap txtbmp = new Aurigma.GraphicsMill.Bitmap(1000, 200, Aurigma.GraphicsMill.PixelFormat.Format1bppIndexed);
using (Aurigma.GraphicsMill.Drawing.GdiGraphics g = txtbmp.GetGdiGraphics())
{
Aurigma.GraphicsMill.Drawing.SolidBrush theBrush = new Aurigma.GraphicsMill.Drawing.SolidBrush(Aurigma.GraphicsMill.RgbColor.Black);
Aurigma.GraphicsMill.Drawing.Font theFont = new Aurigma.GraphicsMill.Drawing.Font(
"Arial",
8,
false,
false,
300,
300);
theFont.Unit = Aurigma.GraphicsMill.Unit.Point;
theFont.Antialiased = true;
g.Clear(Aurigma.GraphicsMill.RgbColor.Transparent);
g.DrawString(
"абвгдеёжзиклмнопрстуфхцчшщъыьэюя",
theFont,
theBrush,
10,
0);
g.DrawString(
"АБВГДЕЁЖЗИКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ",
theFont,
theBrush,
10,
100);
}
It works fine. See the attached picture with russian alphabet. Could you submit case with entire code sample project which reproduces the problem? Edited by user Thursday, May 22, 2008 10:00:26 PM(UTC)
| Reason: Not specified Alex Kon attached the following image(s): |
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.