After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 627644 - add more licences to gtkaboutdialog
add more licences to gtkaboutdialog
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
unspecified
Other Linux
: Normal enhancement
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks: 637316
 
 
Reported: 2010-08-22 12:36 UTC by Christian Persch
Modified: 2014-01-25 03:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Added new licenses and a string to indicate the license version (3.44 KB, patch)
2010-08-22 22:03 UTC, Javier Jardón (IRC: jjardon)
needs-work Details | Review
Add more licences to gtkaboutdialog (7.12 KB, patch)
2010-08-25 18:32 UTC, Javier Jardón (IRC: jjardon)
needs-work Details | Review
Add more licences to gtkaboutdialog: first approach (7.50 KB, patch)
2010-11-21 20:45 UTC, Javier Jardón (IRC: jjardon)
rejected Details | Review
Add more licences to gtkaboutdialog: second approach (8.41 KB, patch)
2010-11-21 20:46 UTC, Javier Jardón (IRC: jjardon)
rejected Details | Review

Description Christian Persch 2010-08-22 12:36:01 UTC
The GtkLicense enum is missing values for "or (at your option), any later version" variants of the [L]GPL{2,3}. And there's no AGPL3[+].
Comment 1 Javier Jardón (IRC: jjardon) 2010-08-22 22:03:43 UTC
Created attachment 168524 [details] [review]
Added new licenses and a string to indicate the license version

The standard template at gnu says to use "or later", but there's no way to see from the about dialogue whether the developer of the programme in question has actually included the "or later"

Also, added GTK_LICENSE_GPL_*_PLUS and GTK_LICENSE_LGPL_*_PLUS to GtkLicense enumeration
Comment 2 Matthias Clasen 2010-08-25 02:10:40 UTC
Review of attachment 168524 [details] [review]:

I don't think this is the best way to go about implementing this. 
I'd rather have this done by varying the license_preamble according to
license_type. I think it might be nice to use the de-facto standard header 
for the gnu licenses for this:

  This program is free software; you can redistribute it and/or
  modify it under the terms of the %{license_name} as published
  by the Free Software Foundation; either version 2 of the License,
  or (at your option) any later version.
 
  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 %{license_link} for more details.

Etc. We can keep using the current preamble text for the non-gnu licenses.

I also think we want to avoid calling _(NULL)
Comment 3 Javier Jardón (IRC: jjardon) 2010-08-25 18:32:23 UTC
Created attachment 168756 [details] [review]
Add more licences to gtkaboutdialog

Here another try.

I've used the standard GNU header from http://www.gnu.org/licenses/gpl-howto.html now.
Comment 4 Emmanuele Bassi (:ebassi) 2010-08-25 20:55:43 UTC
Review of attachment 168756 [details] [review]:

with the license preamble don't we go yet again into the "the translations should be done by a lawyer" territory? is the preamble too legally binding?

if it's okay, then I don't mind.

::: gtk/gtkaboutdialog.c
@@ +2565,3 @@
+        license_name = g_strdup ("GNU Lesser General Public License");
+
+      preamble = g_strdup_printf (gtk_license_gnu_header, license_name, gtk_license_version[license], url);

I'd probably use a GString here, to avoid a g_strdup()+g_strdup_printf() combo.
Comment 5 Matthias Clasen 2010-08-25 22:10:52 UTC
Review of attachment 168756 [details] [review]:

::: gtk/gtkaboutdialog.c
@@ +2633,3 @@
           g_string_append (str, priv->copyright);
           g_string_append (str, "\n\n");
+          g_string_append (str, _(license_preamble));

This is not going to work. If you want the various variants of the preamble to be translated, it is not enough to just mark a single template with N_(). You need to have each variant of the preamble as a separate extracted string (you can play some games with %s, but it is better to just translate complete strings).
Comment 6 Javier Jardón (IRC: jjardon) 2010-11-21 20:45:12 UTC
Created attachment 174982 [details] [review]
Add more licences to gtkaboutdialog: first approach

Another try, we save all the variants in one array
Comment 7 Javier Jardón (IRC: jjardon) 2010-11-21 20:46:11 UTC
Created attachment 174983 [details] [review]
Add more licences to gtkaboutdialog: second approach

Other approach: Use different headers per license. Maybe more readable
Comment 8 Matthias Clasen 2010-11-28 04:33:55 UTC
I'm not happy with any of these, unfortunately. Either they stitch together translated strings with printf, which doesn't really work, or they cause excessive redundancy. And none of them addresses the problem that for a PLUS value, the link is going to be wrong/misleading anyway.
Comment 9 Matthias Clasen 2010-12-20 22:12:04 UTC
Whatever we end up doing here will have to be reevaluated for the about dialog redesign that landed on master recently.
Comment 10 Matthias Clasen 2014-01-25 03:57:07 UTC
commit 63c9342e30f24f4a270a67315c3d75d794855728
Author: William Jon McCann <william.jon.mccann@gmail.com>
Date:   Mon Dec 16 11:06:24 2013 -0500

    about dialog: differentiate GPL "or later" versions
    
    https://bugzilla.gnome.org/show_bug.cgi?id=720410