#include "config.h"
#include <string.h>
#include <glib/gi18n.h>
#include <gtk/gtk.h>
#include "ev-properties-license.h"
Go to the source code of this file.
static void ev_properties_license_add_section |
( |
EvPropertiesLicense * |
properties, |
|
|
const gchar * |
title_text, |
|
|
GtkWidget * |
contents |
|
) |
| |
|
static |
Definition at line 98 of file ev-properties-license.c.
103 GtkWidget *alignment;
106 title = gtk_label_new (NULL);
107 gtk_misc_set_alignment (GTK_MISC (title), 0.0, 0.5);
108 gtk_label_set_use_markup (GTK_LABEL (title),
TRUE);
109 markup = g_strdup_printf (
"<b>%s</b>", title_text);
110 gtk_label_set_markup (GTK_LABEL (title), markup);
113 gtk_widget_show (title);
115 alignment = gtk_alignment_new (0.5, 0.5, 1., 1.);
116 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 12, 0);
117 gtk_container_add (GTK_CONTAINER (alignment), contents);
118 gtk_widget_show (contents);
121 gtk_widget_show (alignment);
GtkWidget* ev_properties_license_new |
( |
void |
) | |
|
Definition at line 159 of file ev-properties-license.c.
164 "orientation", GTK_ORIENTATION_VERTICAL,
167 return GTK_WIDGET (properties_license);
Definition at line 47 of file ev-properties-license.c.
49 GtkWidget *swindow, *textview;
50 GtkTextBuffer *buffer;
52 textview = gtk_text_view_new ();
53 gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW (textview), GTK_WRAP_WORD);
54 gtk_text_view_set_left_margin (GTK_TEXT_VIEW (textview), 8);
55 gtk_text_view_set_right_margin (GTK_TEXT_VIEW (textview), 8);
57 buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (textview));
60 swindow = gtk_scrolled_window_new (NULL, NULL);
61 gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (swindow),
63 gtk_container_add (GTK_CONTAINER (swindow), textview);
64 gtk_widget_show (textview);
static GtkWidget* get_license_uri_widget |
( |
const gchar * |
uri) | |
|
|
static |
Definition at line 70 of file ev-properties-license.c.
76 label = gtk_label_new (NULL);
77 g_object_set (G_OBJECT (label),
81 "ellipsize", PANGO_ELLIPSIZE_END,
84 checked_uri = g_uri_parse_scheme (uri);
86 markup = g_markup_printf_escaped (
"<a href=\"%s\">%s</a>", uri, uri);
87 gtk_label_set_markup (GTK_LABEL (label), markup);
91 gtk_label_set_text (GTK_LABEL (label), uri);