예제 #1
0
void
empathy_about_dialog_new (GtkWindow *parent)
{
	gchar *license_trans;

	gtk_about_dialog_set_url_hook (about_dialog_activate_link_cb, NULL, NULL);

	license_trans = g_strconcat (_(license[0]), "\n\n",
				     _(license[1]), "\n\n",
				     _(license[2]), "\n\n",
				     NULL);

	gtk_show_about_dialog (parent,
			       "artists", artists,
			       "authors", authors,
			       "comments", _("An Instant Messaging client for GNOME"),
			       "license", license_trans,
			       "wrap-license", TRUE,
			       "copyright", "Imendio AB 2002-2007\nCollabora Ltd 2007-2008",
			       "documenters", documenters,
			       "logo-icon-name", "empathy",
			       "translator-credits", _("translator-credits"),
			       "version", PACKAGE_VERSION,
			       "website", WEB_SITE,
			       NULL);

	g_free (license_trans);
}
예제 #2
0
void
twitux_about_dialog_new (GtkWindow *parent)
{
	gchar *license_trans;

	gtk_about_dialog_set_url_hook (about_dialog_activate_link_cb, NULL, NULL);

	license_trans = g_strconcat (_(license[0]), "\n\n", _(license[1]), "\n\n",
								 _(license[2]), "\n\n", NULL);

	gtk_show_about_dialog (parent,
						   "authors", authors,
						   "artists", artists,
						   "comments", _("A GNOME client for Twitter."),
						   "copyright", _("Copyright \xc2\xa9 2007-2009 Daniel Morales"),
						   "license", license_trans,
						   "translator-credits", _("translator-credits"),
						   "version", PACKAGE_VERSION,
						   "website", WEB_SITE,
						   "wrap-license", TRUE,
						   "logo-icon-name", "twitux",
						   NULL);

	g_free (license_trans);
}
예제 #3
0
void
panel_dialogs_show_about (void)
{
  static const gchar *authors[] =
  {
    "Jasper Huijsmans <*****@*****.**>",
    "Nick Schermer <*****@*****.**>",
    "Tic-tac-toe <*****@*****.**>",
    NULL
  };

  gtk_about_dialog_set_email_hook (panel_dialogs_show_about_email_hook, NULL, NULL);
#if !GTK_CHECK_VERSION (2, 18, 0)
  gtk_about_dialog_set_url_hook (exo_gtk_url_about_dialog_hook, NULL, NULL);
#endif

  gtk_show_about_dialog (NULL,
                         "authors", authors,
                         "comments", _("The panel of the Xfce Desktop Environment"),
                         "copyright", "Copyright \302\251 2004-2011 Xfce Development Team",
                         "destroy-with-parent", TRUE,
                         "license", XFCE_LICENSE_GPL,
                         "program-name", PACKAGE_NAME,
                         "translator-credits", _("translator-credits"),
                         "version", PACKAGE_VERSION,
                         "website", "http://www.xfce.org/",
                         "logo-icon-name", PACKAGE_NAME,
                         NULL);

}
예제 #4
0
파일: AboutDialog.c 프로젝트: chan18/ljedit
void puss_show_about_dialog() {
	const gchar* license =
		"This library is free software; you can redistribute it and/or\n"
		"modify it under the terms of the GNU Library General Public License as\n"
		"published by the Free Software Foundation; either version 2 of the\n"
		"License, or (at your option) any later version.\n"
		"\n"
		"This software is distributed in the hope that it will be useful,\n"
		"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
		"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\n"
		"Library General Public License for more details.\n"
		"\n";

	const gchar* authors[] = { "Louis LJ", NULL };

#if GTK_MAJOR_VERSION==2
	gtk_about_dialog_set_email_hook(&cb_about_activate_email, 0, 0);
	gtk_about_dialog_set_url_hook(&cb_about_activate_url, 0, 0);
#endif

	gtk_show_about_dialog( puss_app->main_window
		, "name",      "puss"
		, "version",   "0.1"
		, "copyright", "(C) 2007-2008 The Puss Team"
		, "license",   license
		, "website",   "http://ljedit.googlecode.com"
		, "authors",   authors
		, NULL );
}
예제 #5
0
파일: ml_gtk.c 프로젝트: CRogers/obc
CAMLprim value
ml_gtk_about_dialog_set_url_hook (value hook)
{
  gtk_about_dialog_set_url_hook (&ml_activate_link_func,
				 ml_global_root_new (hook),
				 ml_global_root_destroy);
  return Val_unit;
}
예제 #6
0
void
applet_about_dialog_show (NMApplet *applet)
{
	static const gchar *authors[] = {
		"The Red Hat Desktop Team, including:\n",
		"Christopher Aillon <*****@*****.**>",
		"Jonathan Blandford <*****@*****.**>",
		"John Palmieri <*****@*****.**>",
		"Ray Strode <*****@*****.**>",
		"Colin Walters <*****@*****.**>",
		"Dan Williams <*****@*****.**>",
		"David Zeuthen <*****@*****.**>",
		"\nAnd others, including:\n",
		"Bill Moss <*****@*****.**>",
		"Tom Parker",
		"*****@*****.**",
		"Peter Jones <*****@*****.**>",
		"Robert Love <*****@*****.**>",
		"Tim Niemueller (http://www.niemueller.de)",
		NULL
	};

	static const gchar *artists[] = {
		"Diana Fong <*****@*****.**>",
		NULL
	};


	/* FIXME: unnecessary with libgnomeui >= 2.16.0 */
	static gboolean been_here = FALSE;
	if (!been_here) {
		been_here = TRUE;
		gtk_about_dialog_set_url_hook (about_dialog_handle_url_cb, NULL, NULL);
		gtk_about_dialog_set_email_hook (about_dialog_handle_email_cb, NULL, NULL);
	}

	gtk_show_about_dialog (NULL,
	                       "version", VERSION,
	                       "copyright", _("Copyright \xc2\xa9 2004-2008 Red Hat, Inc.\n"
					                  "Copyright \xc2\xa9 2005-2008 Novell, Inc."),
	                       "comments", _("Notification area applet for managing your network devices and connections."),
	                       "website", "http://www.gnome.org/projects/NetworkManager/",
	                       "website-label", _("NetworkManager Website"),
	                       "authors", authors,
	                       "artists", artists,
	                       "translator-credits", _("translator-credits"),
	                       "logo-icon-name", GTK_STOCK_NETWORK,
	                       NULL);
}
예제 #7
0
void nsgtk_about_dialog_init(GtkWindow *parent, struct browser_window *bw,
                             const char *version)
{
    gchar *licence_text;
    gchar *licence_location = g_strconcat(res_dir_location, "licence", NULL);

    g_file_get_contents(licence_location, &licence_text, NULL, NULL);
    free(licence_location);
    gtk_about_dialog_set_url_hook (launch_url, (gpointer) bw, NULL);

    gtk_show_about_dialog(parent, "artists", artists, "authors", authors,
                          "comments", description,"copyright", copyright,
                          "documenters", documenters, "license", licence_text,
                          "program-name", name, "translator-credits", translators,
                          "version", version, "website", url,
                          "website-label", url_label,
                          "wrap-license", FALSE, NULL);
}
예제 #8
0
/**
 * 创建关于对话框.
 */
GtkWidget *HelpDialog::CreateAboutDialog()
{
        const char *authors[] = {
                _("Jally <*****@*****.**>"),
                _("ManPT <*****@*****.**>"),
                NULL
        };
        const char *artists[] = {
                _("Jally <*****@*****.**>"),
                _("LiWeijian <*****@*****.**>"),
                _("ManPT <*****@*****.**>"),
                NULL
        };
        const char *translators = _("alick <*****@*****.**>\n"
                                     "ManPT <*****@*****.**>");
        GtkWidget *dialog;

        dialog = gtk_about_dialog_new();
        gtk_about_dialog_set_email_hook(
                 GtkAboutDialogActivateLinkFunc(DialogOpenEmail), NULL, NULL);
        gtk_about_dialog_set_url_hook(
                 GtkAboutDialogActivateLinkFunc(DialogOpenUrl), NULL, NULL);
        gtk_about_dialog_set_program_name(GTK_ABOUT_DIALOG(dialog), _("iptux"));
        gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(dialog), VERSION);
        gtk_about_dialog_set_copyright(GTK_ABOUT_DIALOG(dialog),
                                         "Copyright © 2008-2009 by Jally");
        gtk_about_dialog_set_comments(GTK_ABOUT_DIALOG(dialog),
                                         _("A GTK+ based LAN Messenger."));
        gtk_about_dialog_set_website(GTK_ABOUT_DIALOG(dialog),
                                         "http://code.google.com/p/iptux/");
        gtk_about_dialog_set_license(GTK_ABOUT_DIALOG(dialog), "GPL 2+");
        gtk_about_dialog_set_authors(GTK_ABOUT_DIALOG(dialog), authors);
        gtk_about_dialog_set_artists(GTK_ABOUT_DIALOG(dialog), artists);
        gtk_about_dialog_set_translator_credits(GTK_ABOUT_DIALOG(dialog), translators);
        gtk_about_dialog_set_logo_icon_name(GTK_ABOUT_DIALOG(dialog), "ip-tux");

        return dialog;
}
예제 #9
0
int
main(int argc, char** argv) {
#ifdef ENABLE_NLS
    bindtextdomain(GETTEXT_PACKAGE, PACKAGE_LOCALE_DIR);
    bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
    textdomain(GETTEXT_PACKAGE);
#endif
    gtk_init(&argc, &argv);
    glade_init();
    gnome_program_init(PACKAGE, VERSION,
                       LIBGNOME_MODULE,
                       argc, argv,
                       GNOME_PARAM_APP_DATADIR, PACKAGE_DATA_DIR,
                       GNOME_PARAM_HUMAN_READABLE_NAME, _("Font Manager"),
                       NULL);
    gtk_about_dialog_set_url_hook((GtkAboutDialogActivateLinkFunc)fm_url_hook, NULL, NULL);

    glade_set_custom_handler((GladeXMLCustomWidgetHandler)fm_glade_helper, NULL);
    gtk_widget_show(fm_window_new());

    gtk_main();

    return 0;
}
예제 #10
0
파일: aboutdlg.cpp 프로젝트: beanhome/dev
void wxAboutBox(const wxAboutDialogInfo& info, wxWindow* WXUNUSED(parent))
{
    if ( !gtk_check_version(2,6,0) )
    {
        // don't create another dialog if one is already present
        if ( !gs_aboutDialog )
            gs_aboutDialog = GTK_ABOUT_DIALOG(gtk_about_dialog_new());

        GtkAboutDialog * const dlg = gs_aboutDialog;
        gtk_about_dialog_set_program_name(dlg, wxGTK_CONV_SYS(info.GetName()));
        if ( info.HasVersion() )
            gtk_about_dialog_set_version(dlg, wxGTK_CONV_SYS(info.GetVersion()));
        else
            gtk_about_dialog_set_version(dlg, NULL);
        if ( info.HasCopyright() )
            gtk_about_dialog_set_copyright(dlg, wxGTK_CONV_SYS(info.GetCopyrightToDisplay()));
        else
            gtk_about_dialog_set_copyright(dlg, NULL);
        if ( info.HasDescription() )
            gtk_about_dialog_set_comments(dlg, wxGTK_CONV_SYS(info.GetDescription()));
        else
            gtk_about_dialog_set_comments(dlg, NULL);
        if ( info.HasLicence() )
            gtk_about_dialog_set_license(dlg, wxGTK_CONV_SYS(info.GetLicence()));
        else
            gtk_about_dialog_set_license(dlg, NULL);

        wxIcon icon = info.GetIcon();
        if ( icon.IsOk() )
            gtk_about_dialog_set_logo(dlg, info.GetIcon().GetPixbuf());

        if ( info.HasWebSite() )
        {
            // NB: must be called before gtk_about_dialog_set_website() as
            //     otherwise it has no effect (although GTK+ docs don't mention
            //     this...)
            gtk_about_dialog_set_url_hook(wxGtkAboutDialogOnLink, NULL, NULL);

            gtk_about_dialog_set_website(dlg, wxGTK_CONV_SYS(info.GetWebSiteURL()));
            gtk_about_dialog_set_website_label
            (
                dlg,
                wxGTK_CONV_SYS(info.GetWebSiteDescription())
            );
        }
        else
        {
            gtk_about_dialog_set_website(dlg, NULL);
            gtk_about_dialog_set_website_label(dlg, NULL);
            gtk_about_dialog_set_url_hook(NULL, NULL, NULL);
        }

        if ( info.HasDevelopers() )
            gtk_about_dialog_set_authors(dlg, GtkArray(info.GetDevelopers()));
        else
            gtk_about_dialog_set_authors(dlg, GtkArray());
        if ( info.HasDocWriters() )
            gtk_about_dialog_set_documenters(dlg, GtkArray(info.GetDocWriters()));
        else
            gtk_about_dialog_set_documenters(dlg, GtkArray());
        if ( info.HasArtists() )
            gtk_about_dialog_set_artists(dlg, GtkArray(info.GetArtists()));
        else
            gtk_about_dialog_set_artists(dlg, GtkArray());

        wxString transCredits;
        if ( info.HasTranslators() )
        {
            const wxArrayString& translators = info.GetTranslators();
            const size_t count = translators.size();
            for ( size_t n = 0; n < count; n++ )
            {
                transCredits << translators[n] << wxT('\n');
            }
        }
        else // no translators explicitly specified
        {
            // maybe we have translator credits in the message catalog?
            wxString translator = _("translator-credits");

            // gtk_about_dialog_set_translator_credits() is smart enough to
            // detect if "translator-credits" is untranslated and hide the
            // translators tab in that case, however it will still show the
            // "credits" button, (at least GTK 2.10.6) even if there are no
            // credits informations at all, so we still need to do the check
            // ourselves
            if ( translator != wxT("translator-credits") ) // untranslated!
                transCredits = translator;
        }

        if ( !transCredits.empty() )
            gtk_about_dialog_set_translator_credits(dlg, wxGTK_CONV_SYS(transCredits));
        else
            gtk_about_dialog_set_translator_credits(dlg, NULL);

        g_signal_connect(dlg, "response",
                            G_CALLBACK(wxGtkAboutDialogOnClose), NULL);

        gtk_window_present(GTK_WINDOW(dlg));
        return;
    }

    // native about dialog not available, fall back to the generic one
    wxGenericAboutBox(info);
}
예제 #11
0
파일: dialog.c 프로젝트: AurelienTT/viking
void a_dialog_about ( GtkWindow *parent )
{
  const gchar *program_name = PACKAGE_NAME;
  const gchar *version = VIKING_VERSION;
  const gchar *website = VIKING_URL;
  const gchar *copyright = "2003-2008, Evan Battaglia\n2008-"THEYEAR", Viking's contributors";
  const gchar *comments = _("GPS Data and Topo Analyzer, Explorer, and Manager.");
  const gchar *license = _("This program is free software; you can redistribute it and/or modify "
			"it under the terms of the GNU General Public License as published by "
			"the Free Software Foundation; either version 2 of the License, or "
			"(at your option) any later version."
			"\n\n"
			"This program is distributed in the hope that it will be useful, "
			"but WITHOUT ANY WARRANTY; without even the implied warranty of "
			"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the "
			"GNU General Public License for more details."
			"\n\n"
			"You should have received a copy of the GNU General Public License "
			"along with this program; if not, write to the Free Software "
			"Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA");

  // Would be nice to use gtk_about_dialog_add_credit_section (), but that requires gtk 3.4
  // For now shove it in the 'artists' section so at least the information is easily visible
  // Something more advanced might have proper version information too...
  const gchar *libs[] = {
    "Compiled in libraries:",
    // Default libs
    "libglib-2.0",
    "libgthread-2.0",
    "libgtk+-2.0",
    "libgio-2.0",
    // Potentially optional libs (but probably couldn't build without them)
#ifdef HAVE_LIBM
    "libm",
#endif
#ifdef HAVE_LIBZ
    "libz",
#endif
#ifdef HAVE_LIBCURL
    "libcurl",
#endif
#ifdef HAVE_EXPAT_H
    "libexpat",
#endif
    // Actually optional libs
#ifdef HAVE_LIBGPS
    "libgps",
#endif
#ifdef HAVE_LIBGEXIV2
    "libgexiv2",
#endif
#ifdef HAVE_LIBEXIF
    "libexif",
#endif
#ifdef HAVE_LIBX11
    "libX11",
#endif
#ifdef HAVE_LIBMAGIC
    "libmagic",
#endif
#ifdef HAVE_LIBBZ2
    "libbz2",
#endif
#ifdef HAVE_LIBZIP
    "libzip",
#endif
#ifdef HAVE_LIBSQLITE3
    "libsqlite3",
#endif
#ifdef HAVE_LIBMAPNIK
    "libmapnik",
#endif
#ifdef HAVE_LIBNETTLE
    "libnettle",
#endif
    NULL
  };
  // Newer versions of GTK 'just work', calling gtk_show_uri() on the URL or email and opens up the appropriate program
  // This is the old method:
#if (GTK_MAJOR_VERSION == 2 && GTK_MINOR_VERSION < 24)
  gtk_about_dialog_set_url_hook (about_url_hook, NULL, NULL);
  gtk_about_dialog_set_email_hook (about_email_hook, NULL, NULL);
#endif

  gtk_show_about_dialog (parent,
	/* TODO do not set program-name and correctly set info for g_get_application_name */
  	"program-name", program_name,
	"version", version,
	"website", website,
	"comments", comments,
	"copyright", copyright,
	"license", license,
	"wrap-license", TRUE,
	/* logo automatically retrieved via gtk_window_get_default_icon_list */
	"authors", AUTHORS,
	"documenters", DOCUMENTERS,
	"translator-credits", _("Translation is coordinated on http://launchpad.net/viking"),
	"artists", libs,
	NULL);
}
예제 #12
0
struct about gebr_gui_about_setup_ui(const gchar * program, const gchar * description)
{
	struct about about;
	const gchar *authors[] = {
		_("GêBR Core Team:"),
		" ",
		_("Coordinator"),
		"  Ricardo Biloti <*****@*****.**>",
                "  Ph.D. Applied Mathematics",
                "  State University of Campinas, Brazil",
		" ",
                _("Development manager"),
		"  Fabrício Matheus Gonçalves <*****@*****.**>",
                "  B.Sc. Computer Engineering",
                " ",
		_("Developers"),
		"  Eric Keiji <*****@*****.**>",
		"  Ian Liu Rodrigues <*****@*****.**>",
		"  Igor Henrique Soares Nunes <*****@*****.**>",
		"  Jorge Pizzolatto <*****@*****.**>",
		"  Júlia Koury Marques <*****@*****.**>",
		"  Vinícius Oliveira Querência <*****@*****.**>",
		" ",
		_("Consultants"),
		"  Bráulio Oliveira",
		"  Eduardo Filpo, Petrobras",
		"  Fernando Roxo, Prosismo",
		"  Luis Alberto D'Afonseca, CGG",
		"  Rodrigo Portugal, Schlumberger",
                " ",
                _("Former members"),
		"  Alexandre Baaklini",
		"  Davi Clemente",
		"  Fábio Azevedo",
		"  Gabriel Sobral",
		"  Giuliano Roberto Pinheiro",
		"  Priscila Moraes",
		"  Renan William Giarola Miranda",               
		"  Rodrigo Morelatto",
		NULL
	};

#if !GTK_CHECK_VERSION(2,20,0)
	// Instala a funcao que nada faz. Este bug ja foi
	// corrigido no trunk do Gtk+, eu acredito.
	gtk_about_dialog_set_url_hook(__dummy__, NULL, NULL);
#endif

	about.dialog = gtk_about_dialog_new();

	gtk_about_dialog_set_program_name(GTK_ABOUT_DIALOG(about.dialog), program);
	gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(about.dialog), gebr_version());
	gtk_about_dialog_set_logo(GTK_ABOUT_DIALOG(about.dialog), gebr_gui_pixmaps_gebr_logo());
	gtk_about_dialog_set_copyright(GTK_ABOUT_DIALOG(about.dialog), _("GêBR Core Team"));

	gtk_about_dialog_set_license(GTK_ABOUT_DIALOG(about.dialog),
				     _("Copyright (C) 2007-2012 GêBR core team (http://www.gebrproject.com/)\n" "\n"
				       "This program is free software: you can redistribute it and/or modify "
				       "it under the terms of the GNU General Public License as published by "
				       "the Free Software Foundation, either version 3 of the License, or "
				       "(at your option) any later version.\n" "\n"
				       "This program is distributed in the hope that it will be useful, "
				       "but WITHOUT ANY WARRANTY; without even the implied warranty of "
				       "MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the "
				       "GNU General Public License for more details.\n" "\n"
				       "You should have received a copy of the GNU General Public License "
				       "along with this program.  If not, see <http://www.gnu.org/licenses/>.\n" "\n"
				       "In Brazil, this program is under protection against unauthorized usage, "
				       "in accordance to brazilian laws #9609, Feb 19, 1998, #2556, "
				       "Apr 20, 1998, and #9610, Feb 19, 1998, and is registered in "
				       "Instituto Nacional da Propriedade Industrial (INPI) under number 70156."));
	gtk_about_dialog_set_wrap_license(GTK_ABOUT_DIALOG(about.dialog), TRUE);

	gtk_about_dialog_set_website(GTK_ABOUT_DIALOG(about.dialog), "http://www.gebrproject.com/");
	gtk_about_dialog_set_website_label(GTK_ABOUT_DIALOG(about.dialog), _("GêBR Home page"));
	gtk_about_dialog_set_authors(GTK_ABOUT_DIALOG(about.dialog), authors);
	gtk_about_dialog_set_comments(GTK_ABOUT_DIALOG(about.dialog), description);

	g_signal_connect (about.dialog, "close",
			  G_CALLBACK (gtk_widget_hide), about.dialog);

	g_signal_connect (about.dialog, "response",
			  G_CALLBACK (gtk_widget_hide), about.dialog);

	g_signal_connect(about.dialog, "delete-event",
			 G_CALLBACK (gtk_widget_hide_on_delete), NULL);

	return about;
}
예제 #13
0
파일: about.c 프로젝트: Shayan-To/bluefish
static void
about_dialog_create(GtkAction * action, gpointer user_data)
{
	Tbfwin *bfwin = BFWIN(user_data);
	GdkPixbuf *logo;

	const gchar *artists[] = {
		"Dave Lyon",
		NULL
	};

	const gchar *authors[] = {
		"Olivier Sessink <*****@*****.**> (Project leader)",
		"Andrius <*****@*****.**>",
		"Jim Hayward <*****@*****.**>",
		"Daniel Leidert <*****@*****.**>",
		"Shawn Novak <*****@*****.**>",
		"Frédéric Falsetti <*****@*****.**>",
		_("\nDevelopers of previous releases:"),
		"Alastair Porter <*****@*****.**>",
		"Antti-Juhani Kaijanaho",
		"Bo Forslund",
		"Chris Mazuc",
		"Christian Tellefsen <*****@*****.**>",
		"David Arno",
		"Eugene Morenko <*****@*****.**>",
		"Gero Takke",
		"Neil Millar",
		"Oskar Świda <*****@*****.**>",
		"Pablo De Napoli",
		"Rasmus Toftdahl Olesen <*****@*****.**>",
		"Roland Steinbach <*****@*****.**>",
		"Santiago Capel Torres",
		"Yanike Mann <*****@*****.**>",
		_("\nPackage maintainers:"),
		"Debian: Daniel Leidert <*****@*****.**>",
		"Fink: Michèle Garoche <*****@*****.**>, Kevin Horton <*****@*****.**>",
		"Gentoo: Hanno Böck <*****@*****.**>",
		"Mandrake: Todd Lyons <*****@*****.**>",
		"Redhat: Matthias Haase <*****@*****.**>",
		"Windows: Shawn Novak <*****@*****.**>, Daniel Leidert <*****@*****.**>",
		_("\nIf you know of anyone missing from this list,\nplease let us know at:"),
		_("[email protected] <*****@*****.**>"),
		_("\nThanks to all who helped make this software available.\n"),
		NULL
	};

	const gchar *documenters[] = {
		"Scott White <*****@*****.**>",
		"Michèle Garoche <*****@*****.**>",
		"Anita Lewis <*****@*****.**>",
		"Alastair Porter <*****@*****.**>",
		"Daniel Blair <*****@*****.**>",
		"Olivier Sessink <*****@*****.**>",
		"Denny Reeh\n",
		NULL
	};

	const gchar *copyright = "Copyright \xc2\xa9 1998-2015 Olivier Sessink and others.\n";

	/* wrap the license here,
	 * the "wrap-license" property is only available with GTK >= 2.8
	 */
	const gchar *license =
		"This program is free software; you can redistribute it and/or modify it "
		"under the terms of the GNU General Public License as published by "
		"the Free Software Foundation; either version 3 of the License, or "
		"(at your option) any later version.\n"
		"\n"
		"This program is distributed in the hope that it will be useful, "
		"but WITHOUT ANY WARRANTY; without even the implied warranty of "
		"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the "
		"GNU General Public License for more details.\n"
		"\n"
		"You should have received a copy of the GNU General Public License "
		"along with this program.  If not, see http://www.gnu.org/licenses/ .";

	const gchar *comments =
		_
		("An open-source editor for experienced web designers and programmers, supporting many programming and markup languages, but focusing on creating dynamic and interactive websites.");

	/* Translators: This is a special message that shouldn't be translated
	 * literally. It is used in the about box to give credits to
	 * the translators.
	 * Thus, you should translate it to your name and email address and
	 * the name and email address of all translator who have contributed
	 * to this translation (in general: this special locale). Please
	 * use a separate line for every translator ending with a newlines (\n).
	 */
	const gchar *translator_credits = _("translator-credits");

	{
		GError *error = NULL;
		logo = gdk_pixbuf_new_from_file(BLUEFISH_SPLASH_FILENAME, &error);
		if (error) {
			g_print("ERROR while loading splash screen: %s\n", error->message);
			g_error_free(error);
		}
	}

#if !GTK_CHECK_VERSION(3, 0, 0)
	gtk_about_dialog_set_url_hook(about_activate_url, NULL, NULL);
#endif /* gtk3 */
#ifndef MAC_INTEGRATION
	gtk_show_about_dialog(GTK_WINDOW(bfwin->main_window), "logo", logo, "name", PACKAGE,
#ifdef SVN_REVISION
						  "version", VERSION " rev" SVN_REVISION,
#else	/* SVN_REVISION */
						  "version", VERSION,
#endif	/* SVN_REVISION */
						  "comments", comments,
						  "copyright", copyright,
						  "license", license,
						  "website", "http://bluefish.openoffice.nl",
						  "authors", authors,
						  "artists", artists,
						  "documenters", documenters,
						  "translator_credits", translator_credits,
						  "wrap-license", TRUE,
						  NULL);

	if (logo)
		g_object_unref(logo);
#else
/* gtk_show_about_dialog hides window when it is closed (no other choices). On OSX this hidden dead window can be accessed from WIndow menu, so we have
to construct about dialog manually and destroy it after use */
	GtkWidget *dialog;
	dialog = gtk_about_dialog_new();
	gtk_window_set_transient_for(GTK_WINDOW( dialog ), GTK_WINDOW(bfwin->main_window));
	gtk_window_set_destroy_with_parent (GTK_WINDOW(dialog), TRUE);
	g_signal_connect (dialog, "activate-link", G_CALLBACK (activate_link_lcb), NULL);
         /* Set it's properties */
	gtk_about_dialog_set_program_name(GTK_ABOUT_DIALOG(dialog), "Bluefish" );
	gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(dialog),
#ifdef SVN_REVISION
						  VERSION " rev" SVN_REVISION
#else	/* SVN_REVISION */
					  VERSION
#endif	/* SVN_REVISION */
	 );
	gtk_about_dialog_set_copyright(GTK_ABOUT_DIALOG(dialog), copyright);
	gtk_about_dialog_set_website(GTK_ABOUT_DIALOG(dialog), "http://bluefish.openoffice.nl" );
	gtk_about_dialog_set_authors(GTK_ABOUT_DIALOG(dialog), authors);
	gtk_about_dialog_set_artists(GTK_ABOUT_DIALOG(dialog), artists);
	gtk_about_dialog_set_documenters(GTK_ABOUT_DIALOG(dialog), documenters);
	gtk_about_dialog_set_license(GTK_ABOUT_DIALOG(dialog), license);
	gtk_about_dialog_set_comments(GTK_ABOUT_DIALOG(dialog), comments);
	gtk_about_dialog_set_translator_credits(GTK_ABOUT_DIALOG(dialog), translator_credits);
	gtk_about_dialog_set_wrap_license(GTK_ABOUT_DIALOG(dialog), TRUE);
	gtk_about_dialog_set_logo(GTK_ABOUT_DIALOG(dialog), logo);
	g_object_unref(logo), logo=NULL;
    /* Run dialog and destroy it after it returns. */
    gtk_dialog_run( GTK_DIALOG(dialog) );
    gtk_widget_destroy(GTK_WIDGET(dialog));
#endif /* MAC_INTEGRATION */
}
예제 #14
0
GtkWidget *
about_dialog_create (GimpContext *context)
{
  static GimpAboutDialog *dialog = NULL;

  g_return_val_if_fail (GIMP_IS_CONTEXT (context), NULL);

  if (! dialog)
    {
      GtkWidget *widget;
      GtkWidget *container;
      GdkPixbuf *pixbuf;
      GList     *children;

      if (gimp_pdb_lookup_procedure (context->gimp->pdb, PDB_URL_LOAD))
        gtk_about_dialog_set_url_hook (about_dialog_load_url,
                                       g_object_ref (context),
                                       (GDestroyNotify) g_object_unref);

      dialog = g_new0 (GimpAboutDialog, 1);

      dialog->n_authors = G_N_ELEMENTS (authors) - 1;

      pixbuf = about_dialog_load_logo ();

      widget = g_object_new (GTK_TYPE_ABOUT_DIALOG,
                             "role",               "about-dialog",
                             "window-position",    GTK_WIN_POS_CENTER,
                             "title",              _("About GIMP"),
                             (gtk_check_version (2, 12, 0) ?
                              "name" :
                              "program-name"),     GIMP_ACRONYM,
                             "version",            GIMP_VERSION,
                             "copyright",          GIMP_COPYRIGHT,
                             "comments",           GIMP_NAME,
                             "license",            GIMP_LICENSE,
                             "wrap-license",       TRUE,
                             "logo",               pixbuf,
                             "website",            "http://www.gimp.org/",
                             "website-label",      _("Visit the GIMP website"),
                             "authors",            authors,
                             "artists",            artists,
                             "documenters",        documenters,
                             /* Translators: insert your names here,
                              * separated by newline
                              */
                             "translator-credits", _("translator-credits"),
                             NULL);

      if (pixbuf)
        g_object_unref (pixbuf);

      dialog->dialog = widget;

      g_object_add_weak_pointer (G_OBJECT (widget), (gpointer) &dialog);

      g_signal_connect (widget, "response",
                        G_CALLBACK (gtk_widget_destroy),
                        NULL);

      g_signal_connect (widget, "map",
                        G_CALLBACK (about_dialog_map),
                        dialog);
      g_signal_connect (widget, "unmap",
                        G_CALLBACK (about_dialog_unmap),
                        dialog);

      /*  kids, don't try this at home!  */
      container = GTK_DIALOG (widget)->vbox;
      children = gtk_container_get_children (GTK_CONTAINER (container));

      if (GTK_IS_VBOX (children->data))
        {
          about_dialog_add_animation (children->data, dialog);
          about_dialog_add_message (children->data);
        }
      else
        g_warning ("%s: ooops, no vbox in this container?", G_STRLOC);

      g_list_free (children);
    }

  gtk_window_present (GTK_WINDOW (dialog->dialog));

  return dialog->dialog;
}
예제 #15
0
static void
help_about_action_cb(GtkAction *action, WordListWindow *window)
{
  const gchar *name = N_("uim-dict");
#if GTK_CHECK_VERSION(2, 6, 0)
  GdkPixbuf *pixbuf, *transparent;
  const gchar *filename = UIM_PIXMAPSDIR "/uim-dict.png";
  const gchar *authors[] = {
    "Masahito Omote <*****@*****.**>",
    "Takuro Ashie",
    "Etsushi Kato",
    NULL
  };
  const gchar *copyright = N_(
    "Copyright (C) 2003-2004 Masahito Omote\n"
    "Copyright (C) 2004-2013 uim Project\n"
    "All rights reserved.");

  transparent = NULL;
  pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
  if (pixbuf) {
    transparent = gdk_pixbuf_add_alpha(pixbuf, TRUE, 0xff, 0xff, 0xff);
    g_object_unref(pixbuf);
  }
  
#if !GTK_CHECK_VERSION(2, 18, 0)
  gtk_about_dialog_set_url_hook (activate_url, NULL, NULL);
#endif
  gtk_show_about_dialog (GTK_WINDOW(window),
			 "name", name,
			 "version", VERSION,
			 "copyright", copyright,
			 "website", "https://github.com/uim/uim",
			 "authors", authors,
			 "logo", transparent,
			 NULL);
  g_object_unref(transparent);
#else
  GtkWidget *about_dialog, *label1;
  const gchar *copyright = N_(
    "Copyright 2003-2004 Masahito Omote &lt;[email protected]&gt;\n"
    "Copyright 2004-2013 uim Project https://github.com/uim/uim\n"
    "All rights reserved.");
  gchar *about_name =
    g_strdup_printf("<span size=\"20000\">%s %s </span>\n\n<span size=\"14000\">%s </span>\n", _(name), VERSION, _(copyright));

  about_dialog = gtk_dialog_new_with_buttons(_("About uim-dict"), NULL,
					     GTK_DIALOG_MODAL,
					     GTK_STOCK_OK,
					     GTK_RESPONSE_ACCEPT, NULL);
  gtk_container_set_border_width(GTK_CONTAINER(about_dialog), 8);

  label1 = gtk_label_new(NULL);
  gtk_widget_show(label1);
  gtk_label_set_markup(GTK_LABEL(label1), about_name);
  g_free(about_name);
  gtk_box_pack_start(
      GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(about_dialog))),
      label1, FALSE, FALSE, 0);

  gtk_window_set_transient_for(GTK_WINDOW(about_dialog),
			       GTK_WINDOW(window));
  gtk_window_set_position(GTK_WINDOW(about_dialog),
			  GTK_WIN_POS_CENTER_ON_PARENT);
  gtk_dialog_run(GTK_DIALOG(about_dialog));

  gtk_widget_destroy(about_dialog);
#endif
}