|
List Info
Thread: Problem Using Persian Fonts
|
|
| Problem Using Persian Fonts |

|
2006-05-08 06:33:29 |
|
Hi Everybody
I tried to compile and run an example which I found from the list.
I installed Persian fonts and changed the source in order to show
some Farsi texts, the program compiles and runs without any errors, but
it can not load the font which I specify.
Other applications like OpenOffice and KOffice recognize my fonts.
Any ideas?
Regards
Ali
Code:
#include <gtk/gtk.h>
int size=15;
void g_exit_callback(GtkWidget *w) { gtk_main_quit(); }
gboolean play_font(gpointer data)
{
GdkRectangle updateRect;
updateRect.x=0; updateRect.y=0;
updateRect.width=240; updateRect.height=320;
gtk_widget_draw(GTK_WIDGET(data),&updateRect);
}
void drawing_callback(GtkWidget *lWidget)
{
printf("drawing_callback\n");
PangoContext *context=NULL;
PangoLayout *layout=NULL;
PangoFontDescription *fontdesc=NULL;
| |