[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gtk2 font troubles



salam -- one more thing -- this only happens with tashkeel.  i
have the same thing happen using katoob too.

here is a screenshot from part of the gtktextview:
www.prism.gatech.edu/~gte440v/other/tashkeel.png

i am also emailing the gtk-app-devel-list about this too.  i'd
appreciate any help insha'Allah.  it only seems to happen w/big
fonts (like that's size 22).  and any fonts, tahoma kasct fonts,
etc.

walsalams.
-ahmed

> 
> salam..
> i am having a really hard time with arabic fonts with gtk2...
> when they're really small, they look fine, when they are big,
> they render with spaces in between some of the letters and its
> really annoying :(
> 
> can someone please look at these few lines of code and tell me
> what i am doing wrong?  thanks...
> 
>   /* create new textbuffer, we can erase old one */
>    tb = gtk_text_buffer_new(NULL);
>    gtk_text_buffer_get_start_iter(tb, &textIter);
> 
>    /* set pango font description */
>    fd = pango_font_description_from_string("KacstQr 22");
>    /* modify font for w which is the GtkTextView widget */
>    gtk_widget_modify_font(GTK_WIDGET(w), fd);
>    pango_font_description_free (fd);
>    
>    /* get arabic text ayah */
>    ayah = quran_read_verse(q, 1, 1, &ctx);
> 
>    /* set tag */
>    tag = gtk_text_buffer_create_tag(tb, "bismillah",
> "justification",
>                                     GTK_JUSTIFY_CENTER,
> "direction",
>                                     GTK_TEXT_DIR_RTL, NULL);
> 
>    /* display... */
>    gtk_text_buffer_insert_with_tags(tb, &textIter, ayah, -1,
> tag, NULL);
>    free(ayah);
> 
>    quran_close(q, &ctx);   
>    /* update buffer */
>    gtk_text_view_set_buffer(GTK_TEXT_VIEW(w), tb);
> 
> 
> walsalams.
> -ahmed
> ________________________________
> 15 Mbytes Free Web-based and  POP3
> Sign up now: http://www.gawab.com
> _______________________________________________
> Developer mailing list
> Developer at arabeyes dot org
> http://lists.arabeyes.org/mailman/listinfo/developer
> 

________________________________
15 Mbytes Free Web-based and  POP3
Sign up now: http://www.gawab.com