[<<] [<] Page 1 of 2 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Using own true type font with Nano-X
From: Kiran Mahajan ####@####.#### Date: 20 Sep 2006 08:04:41 +0100 Message-Id: <1158736753.3565.9.camel@KiranLinux> Hi All, I have putted mail on the list previously regarding this. I want to use my own True Type Font with Nano-X, I have putted that font in fonts/truetype directory. I tried to recompile fontdemo sample program where i am using my font, but while running it i am getting error that "font not found" and it uses the first default font. what i need to do to use my font with Nano-X. I have made freetype support ON and font directory path is also correct. Please give me some pointers to resolve this problem. Is there any thing i am missing? Thanks and regards, Kiran | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
RE: [nanogui] Using own true type font with Nano-X
From: "Martin Kajdas" ####@####.#### Date: 21 Sep 2006 16:01:00 +0100 Message-Id: <CF2BB830A62F914F848E5AD5FFF57AC229155F@mkmail.MKPROD.COM> You also need to update the 'fonts.dir' file. There was a problem with loadfont.c file that I provided a patch for. You may want to search for that too. The TTF fonts work for me. Martin -----Original Message----- From: Kiran Mahajan ####@####.#### Sent: Wednesday, September 20, 2006 12:19 AM To: Nano-X Subject: [nanogui] Using own true type font with Nano-X Hi All, I have putted mail on the list previously regarding this. I want to use my own True Type Font with Nano-X, I have putted that font in fonts/truetype directory. I tried to recompile fontdemo sample program where i am using my font, but while running it i am getting error that "font not found" and it uses the first default font. what i need to do to use my font with Nano-X. I have made freetype support ON and font directory path is also correct. Please give me some pointers to resolve this problem. Is there any thing i am missing? Thanks and regards, Kiran --------------------------------------------------------------------- To unsubscribe, e-mail: ####@####.#### For additional commands, e-mail: ####@####.#### | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
RE: [nanogui] Using own true type font with Nano-X
From: Kiran Mahajan ####@####.#### Date: 25 Sep 2006 15:32:55 +0100 Message-Id: <1159195680.3399.12.camel@KiranLinux> Thanks Martin for reply. I have already updated font.dir, but still i am getting same error. I am not using nxlib. I just trying to run fontdemo program with my truetype font. But its not able to find that font. I am not able to understand why it is not able to find that font? I tried by disabling other font supports for sake of trial, but ended up in the same result! regards, Kiran On Thu, 2006-09-21 at 08:00 -0700, Martin Kajdas wrote: > You also need to update the 'fonts.dir' file. > There was a problem with loadfont.c file that I provided a patch for. > You may want to search for that too. > The TTF fonts work for me. > Martin > > > -----Original Message----- > From: Kiran Mahajan ####@####.#### > Sent: Wednesday, September 20, 2006 12:19 AM > To: Nano-X > Subject: [nanogui] Using own true type font with Nano-X > > > Hi All, > I have putted mail on the list previously regarding this. > I want to use my own True Type Font with Nano-X, I have putted that font > in fonts/truetype directory. > I tried to recompile fontdemo sample program where i am using my font, > but while running it i am getting error that "font not found" and it > uses the first default font. > what i need to do to use my font with Nano-X. > I have made freetype support ON and font directory path is also correct. > Please give me some pointers to resolve this problem. > Is there any thing i am missing? > > Thanks and regards, > Kiran > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: ####@####.#### > For additional commands, e-mail: ####@####.#### > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
RE: [nanogui] Using own true type font with Nano-X
From: "Martin Kajdas" ####@####.#### Date: 25 Sep 2006 15:56:16 +0100 Message-Id: <CF2BB830A62F914F848E5AD5FFF57AC2291563@mkmail.MKPROD.COM> When I was debugging my problem with 'TTF fonts not found', I put a printf() in a search (loadfont) routine to show me what fonts were searched and what font I was looking for. This showed me exactly what the problem was. I cannot tell you what your problem is without knowing what is going on. Do the printf's and then we will see. It is either looking for a wrong front (no match) or at the wrong directory. Martin -----Original Message----- From: Kiran Mahajan ####@####.#### Sent: Monday, September 25, 2006 7:48 AM To: Martin Kajdas; Nano-X Subject: RE: [nanogui] Using own true type font with Nano-X Thanks Martin for reply. I have already updated font.dir, but still i am getting same error. I am not using nxlib. I just trying to run fontdemo program with my truetype font. But its not able to find that font. I am not able to understand why it is not able to find that font? I tried by disabling other font supports for sake of trial, but ended up in the same result! regards, Kiran | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
RE: [nanogui] Using own true type font with Nano-X
From: Kiran Mahajan ####@####.#### Date: 28 Sep 2006 14:19:24 +0100 Message-Id: <1159450463.3404.24.camel@KiranLinux> hi Martine, Sorry but i couldn't find loadfont routine you said me! but i am sending the changes i have made in "fontdemo.c" file for debugging purpose along with the output i am getting. The GrGetFontList() is showing my fonts (dvsr0ntt.ttf and DVWSR0NT.TTF). Please have a look and tell me what would be the problem? ********************************************************************* static void do_paint(GR_EVENT_EXPOSURE *ep) { int i, y = 0; //for (i=3; i<=30; ++i) { GR_FONT_INFO info; unsigned char buf[64]; //Kiran's additions GR_FONTLIST **fontlist; int nofonts; GrGetFontList(&fontlist, &nofonts); for(i=0; i<nofonts; i++) { printf("%d> TTF name: %s, MW name: %s\n", (i+1), fontlist[i]->ttname, fontlist[i]->mwname); } GrFreeFontList(&fontlist, nofonts); //end Kiran's additions font = GrCreateFont(FONTNAME, 20, NULL); //Kiran's addition printf("\nValue of font: %d\n", font); GrGetFontInfo(font, &info); printf("\nFont Info..........\n"); printf("\tMax Width : %d\n", info.maxwidth); printf("\tHeight : %d\n", info.height); printf("\tFirst Char: %d\n", info.firstchar); printf("\tLast Char : %d\n", info.lastchar); //end Kiran's addition if (aa) GrSetFontAttr(font, GR_TFANTIALIAS|GR_TFKERNING, 0); /*GrSetFontRotation(font, 150);*/ GrSetGCFont(gc, font); //Kiran's addition buf[0] = 0xCA; buf[1] = 0x45; buf[2] = 0xAE; buf[3] = 0x68; buf[4] = 0xC9; buf[5] = '\0'; //buf[6] = ; //buf[7] = ; //sprintf(buf, "%d The Quick Brown Fox Jumped Over The Lazy Dog", i); GrText(w, gc, 0, y, buf, 5, GR_TFASCII|GR_TFTOP); //end Kiran's addition //GrGetFontInfo(font, &info); y += info.height; GrDestroyFont(font); //} } ********************************************************************* Output i am getting is ******************************************************************* 1> TTF name: OmegaSerif88594 Bold, MW name: lt4-b-omega-serif.ttf 2> TTF name: OmegaSerifVISCII, MW name: viscii-omega-serif.ttf 3> TTF name: Courier New Italic, MW name: couri.ttf 4> TTF name: Arial Italic, MW name: ariali.ttf 5> TTF name: OmegaSerif88593 Italic, MW name: lt3-i-omega-serif.ttf 6> TTF name: OmegaSerif88591, MW name: lt1-r-omega-serif.ttf 7> TTF name: Courier New, MW name: cour.ttf 8> TTF name: OmegaSerif88595 Bold, MW name: lt5-b-omega-serif.ttf 9> TTF name: OmegaSerif88592 Bold, MW name: lt2-b-omega-serif.ttf . . . 23> TTF name: DV-TTSurekh Normal, MW name: dvsr0ntt.ttf 24> TTF name: Arial Black, MW name: ariblk.ttf 25> TTF name: OmegaSerif88592 Italic, MW name: lt2-i-omega-serif.ttf . . . 37> TTF name: DVW-TTSurekh Normal, MW name: DVWSR0NT.TTF 38> TTF name: OmegaSerif88592 BoldItalic, MW name: lt2-bi-omega- serif.ttf 39> TTF name: OmegaSerif88595 BoldItalic, MW name: lt5-bi-omega- serif.ttf fnt_createfont: DVWSR0NT.TTF,20 not found pcf_createfont: DVWSR0NT.TTF,20 not found freetype_createfont: DVWSR0NT.TTF,20 not found createfont: (height != 0) using builtin font System (0) Value of font: 1000 Font Info.......... Max Width : 11 Height : 13 First Char: 32 Last Char : 255 ************************************************************** If it could show my font through GrGetFontList() then why it could not found my font while GrCreateFont()? thanks and regards, Kiran On Mon, 2006-09-25 at 07:56 -0700, Martin Kajdas wrote: > When I was debugging my problem with 'TTF fonts not found', I put a > printf() in a search (loadfont) routine to show me what fonts were > searched and what font I was looking for. > This showed me exactly what the problem was. > I cannot tell you what your problem is without knowing what is going on. > Do the printf's and then we will see. > It is either looking for a wrong front (no match) or at the wrong > directory. > > Martin > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Using own true type font with Nano-X
From: "Greg Haerr" ####@####.#### Date: 28 Sep 2006 16:08:36 +0100 Message-Id: <0acf01c6e30f$f0dda530$2f01a8c0@HaydenLake> : freetype_createfont: DVWSR0NT.TTF,20 not found Is your font actually named within the filesystem in upper case? This looks like an MSDOS compatibility issue, and the Linux filesystem differentiates between upper and lower case. Regards, Greg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
RE: [nanogui] Using own true type font with Nano-X
From: "Martin Kajdas" ####@####.#### Date: 28 Sep 2006 16:22:27 +0100 Message-Id: <CF2BB830A62F914F848E5AD5FFF57AC2291569@mkmail.MKPROD.COM> The problem with TTF fonts is that inside the 'loadfont' routine it generates a file name differently than the ones you printed. It uses the size/bold/italic of the font also. You need the print the files names it searches for in loadfont.c to really find out why it is failing. Martin -----Original Message----- From: Kiran Mahajan ####@####.#### Sent: Thursday, September 28, 2006 6:34 AM To: Martin Kajdas; Nano-X Subject: RE: [nanogui] Using own true type font with Nano-X hi Martine, Sorry but i couldn't find loadfont routine you said me! but i am sending the changes i have made in "fontdemo.c" file for debugging purpose along with the output i am getting. The GrGetFontList() is showing my fonts (dvsr0ntt.ttf and DVWSR0NT.TTF). Please have a look and tell me what would be the problem? ********************************************************************* static void do_paint(GR_EVENT_EXPOSURE *ep) { int i, y = 0; //for (i=3; i<=30; ++i) { GR_FONT_INFO info; unsigned char buf[64]; //Kiran's additions GR_FONTLIST **fontlist; int nofonts; GrGetFontList(&fontlist, &nofonts); for(i=0; i<nofonts; i++) { printf("%d> TTF name: %s, MW name: %s\n", (i+1), fontlist[i]->ttname, fontlist[i]->mwname); } GrFreeFontList(&fontlist, nofonts); //end Kiran's additions font = GrCreateFont(FONTNAME, 20, NULL); //Kiran's addition printf("\nValue of font: %d\n", font); GrGetFontInfo(font, &info); printf("\nFont Info..........\n"); printf("\tMax Width : %d\n", info.maxwidth); printf("\tHeight : %d\n", info.height); printf("\tFirst Char: %d\n", info.firstchar); printf("\tLast Char : %d\n", info.lastchar); //end Kiran's addition if (aa) GrSetFontAttr(font, GR_TFANTIALIAS|GR_TFKERNING, 0); /*GrSetFontRotation(font, 150);*/ GrSetGCFont(gc, font); //Kiran's addition buf[0] = 0xCA; buf[1] = 0x45; buf[2] = 0xAE; buf[3] = 0x68; buf[4] = 0xC9; buf[5] = '\0'; //buf[6] = ; //buf[7] = ; //sprintf(buf, "%d The Quick Brown Fox Jumped Over The Lazy Dog", i); GrText(w, gc, 0, y, buf, 5, GR_TFASCII|GR_TFTOP); //end Kiran's addition //GrGetFontInfo(font, &info); y += info.height; GrDestroyFont(font); //} } ********************************************************************* Output i am getting is ******************************************************************* 1> TTF name: OmegaSerif88594 Bold, MW name: lt4-b-omega-serif.ttf 2> TTF name: OmegaSerifVISCII, MW name: viscii-omega-serif.ttf 3> TTF name: Courier New Italic, MW name: couri.ttf 4> TTF name: Arial Italic, MW name: ariali.ttf 5> TTF name: OmegaSerif88593 Italic, MW name: lt3-i-omega-serif.ttf 6> TTF name: OmegaSerif88591, MW name: lt1-r-omega-serif.ttf 7> TTF name: Courier New, MW name: cour.ttf 8> TTF name: OmegaSerif88595 Bold, MW name: lt5-b-omega-serif.ttf 9> TTF name: OmegaSerif88592 Bold, MW name: lt2-b-omega-serif.ttf . . . 23> TTF name: DV-TTSurekh Normal, MW name: dvsr0ntt.ttf 24> TTF name: Arial Black, MW name: ariblk.ttf 25> TTF name: OmegaSerif88592 Italic, MW name: lt2-i-omega-serif.ttf . . . 37> TTF name: DVW-TTSurekh Normal, MW name: DVWSR0NT.TTF 38> TTF name: OmegaSerif88592 BoldItalic, MW name: lt2-bi-omega- serif.ttf 39> TTF name: OmegaSerif88595 BoldItalic, MW name: lt5-bi-omega- serif.ttf fnt_createfont: DVWSR0NT.TTF,20 not found pcf_createfont: DVWSR0NT.TTF,20 not found freetype_createfont: DVWSR0NT.TTF,20 not found createfont: (height != 0) using builtin font System (0) Value of font: 1000 Font Info.......... Max Width : 11 Height : 13 First Char: 32 Last Char : 255 ************************************************************** If it could show my font through GrGetFontList() then why it could not found my font while GrCreateFont()? thanks and regards, Kiran On Mon, 2006-09-25 at 07:56 -0700, Martin Kajdas wrote: > When I was debugging my problem with 'TTF fonts not found', I put a > printf() in a search (loadfont) routine to show me what fonts were > searched and what font I was looking for. > This showed me exactly what the problem was. > I cannot tell you what your problem is without knowing what is going on. > Do the printf's and then we will see. > It is either looking for a wrong front (no match) or at the wrong > directory. > > Martin > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Using own true type font with Nano-X
From: Kiran Mahajan ####@####.#### Date: 29 Sep 2006 09:21:44 +0100 Message-Id: <1159519008.3401.9.camel@KiranLinux> thanks for reply. yes it is in upper case on my file system also. you could know it by having a look at the output i have sent. it is showing MW name in upper case. I had this doubt so i tried by renaming my other true type file (dvsr0ntt.ttf) to lower case but can't succeed! thanks and regards, Kiran On Thu, 2006-09-28 at 08:41 -0700, Greg Haerr wrote: > : and i am setting FONTNAME to DVWSR0NT.TTF (means in upper case) in the > : fontdemo.c file. > > I'm talking about the filename on your system, not in the .c file. > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Using own true type font with Nano-X
From: "Greg Haerr" ####@####.#### Date: 30 Sep 2006 16:24:11 +0100 Message-Id: <11a401c6e4a4$79a788f0$2f01a8c0@HaydenLake> : I had this doubt so i tried by renaming my other true type file : (dvsr0ntt.ttf) to lower case but can't succeed! : > : and i am setting FONTNAME to DVWSR0NT.TTF (means in upper case) in the The above fonts are different names. My suggestion is to work only with ONE font, and debug the problem one font at a time. The TTF system works, so its likely a font naming or upper/lower case problem. Change your system to use only a single font. Perhaps the font conversion utility is putting the font name inside the font file with the wrong case? Regards, Greg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Using own true type font with Nano-X
From: Kiran Mahajan ####@####.#### Date: 3 Oct 2006 17:09:51 +0100 Message-Id: <1159892699.3393.23.camel@KiranLinux> thanks! I tried with the one font first. I tried with the font dvsr0ntt.ttf. name of this font was in upper case. I checked with it by keeping it in upper case, then after getting error I renamed it to lower case. after doing with this font i tried with other font (DVWSR0NT.TTF) also for sake doubt! but end up with same result. I have made entry for both the fonts in the font.dir. Is there any other file where I need to make entry for those fonts? thanks and regards, Kiran On Sat, 2006-09-30 at 08:24 -0700, Greg Haerr wrote: > The above fonts are different names. > > My suggestion is to work only with ONE font, and > debug the problem one font at a time. The > TTF system works, so its likely a font naming or > upper/lower case problem. Change your system > to use only a single font. Perhaps the font conversion > utility is putting the font name inside the font file with > the wrong case? > > Regards, > > Greg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 2 [>] [>>] |