From: rodin Date: Fri, 5 Jun 2009 12:12:59 +0000 (+0000) Subject: Added a better default font, line spacing and margins X-Git-Tag: v0.9~366 X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;h=d2379f1ae607ccb5391f36969d566bf6be0a24cd;p=projects%2Fchimara%2Fchimara.git Added a better default font, line spacing and margins --- diff --git a/libchimara/style.c b/libchimara/style.c index 698536f..2db2e09 100644 --- a/libchimara/style.c +++ b/libchimara/style.c @@ -65,8 +65,8 @@ style_init_textbuffer(GtkTextBuffer *buffer) gtk_text_buffer_create_tag(buffer, "normal", NULL); gtk_text_buffer_create_tag(buffer, "emphasized", "style", PANGO_STYLE_ITALIC, NULL); gtk_text_buffer_create_tag(buffer, "preformatted", "font-desc", glk_data->monospace_font_desc, NULL); - gtk_text_buffer_create_tag(buffer, "header", "size-points", 16.0, "weight", PANGO_WEIGHT_BOLD, NULL); - gtk_text_buffer_create_tag(buffer, "subheader", "size-points", 12.0, "weight", PANGO_WEIGHT_BOLD, NULL); + gtk_text_buffer_create_tag(buffer, "header", "size-points", 18.0, "weight", PANGO_WEIGHT_BOLD, NULL); + gtk_text_buffer_create_tag(buffer, "subheader", "size-points", 14.0, "weight", PANGO_WEIGHT_BOLD, NULL); gtk_text_buffer_create_tag(buffer, "alert", "foreground", "#aa0000", "weight", PANGO_WEIGHT_BOLD, NULL); gtk_text_buffer_create_tag(buffer, "note", "foreground", "#aaaa00", "weight", PANGO_WEIGHT_BOLD, NULL); gtk_text_buffer_create_tag(buffer, "block-quote", "justification", GTK_JUSTIFY_CENTER, "style", PANGO_STYLE_ITALIC, NULL); diff --git a/libchimara/window.c b/libchimara/window.c index dea1fb6..5e0ec50 100644 --- a/libchimara/window.c +++ b/libchimara/window.c @@ -454,6 +454,9 @@ glk_window_open(winid_t split, glui32 method, glui32 size, glui32 wintype, gtk_text_view_set_wrap_mode( GTK_TEXT_VIEW(textview), GTK_WRAP_WORD_CHAR ); gtk_text_view_set_editable( GTK_TEXT_VIEW(textview), FALSE ); + gtk_text_view_set_pixels_inside_wrap( GTK_TEXT_VIEW(textview), 3 ); + gtk_text_view_set_left_margin( GTK_TEXT_VIEW(textview), 20 ); + gtk_text_view_set_right_margin( GTK_TEXT_VIEW(textview), 20 ); gtk_container_add( GTK_CONTAINER(scrolledwindow), textview ); gtk_widget_show_all(scrolledwindow); diff --git a/tests/main.c b/tests/main.c index 5362b4a..ee011a2 100644 --- a/tests/main.c +++ b/tests/main.c @@ -73,8 +73,8 @@ create_window(void) glk = chimara_glk_new(); g_object_set(glk, "border-width", 6, "spacing", 6, NULL); - chimara_glk_set_default_font_string(CHIMARA_GLK(glk), "Sans 11"); - chimara_glk_set_monospace_font_string(CHIMARA_GLK(glk), "Monospace 10"); + chimara_glk_set_default_font_string(CHIMARA_GLK(glk), "Serif 12"); + chimara_glk_set_monospace_font_string(CHIMARA_GLK(glk), "Monospace 12"); g_signal_connect(glk, "started", G_CALLBACK(on_started), NULL); g_signal_connect(glk, "stopped", G_CALLBACK(on_stopped), NULL);