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 698611 - Language not setup correctly
Language not setup correctly
Status: RESOLVED FIXED
Product: gnome-initial-setup
Classification: Applications
Component: general
0.9
Other Linux
: Normal normal
: ---
Assigned To: Michael Wood
GNOME Initial Setup maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2013-04-22 20:02 UTC by Michael Wood
Modified: 2013-04-30 14:46 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Actually set the user and system lang (10.59 KB, patch)
2013-04-24 19:36 UTC, Michael Wood
reviewed Details | Review
0001-language-Ensure-accountsservice-is-initialized-befor.patch (2.33 KB, patch)
2013-04-30 12:56 UTC, Colin Walters
none Details | Review
language: Ensure accountsservice is initialized (1.76 KB, patch)
2013-04-30 14:23 UTC, Michael Wood
committed Details | Review

Description Michael Wood 2013-04-22 20:02:52 UTC
If you select a Language in initial-setup it is not applied when the user logs in.
Comment 1 Michael Wood 2013-04-23 16:47:08 UTC
The same problem with input selection I believe. Where the calls to org.freedekstop.locale1 aren't made.
Comment 2 Rui Matos 2013-04-23 17:01:07 UTC
(In reply to comment #1)
> The same problem with input selection I believe. Where the calls to
> org.freedekstop.locale1 aren't made.

No, that shouldn't be done in g-i-s since that interface is for system keyboard layouts, i.e. it writes out a xorg.conf snippet. The user's input sources exist only in the user's dconf database and that's already handled by the keyboard page code.
Comment 3 Michael Wood 2013-04-24 19:36:08 UTC
Created attachment 242360 [details] [review]
Actually set the user and system lang
Comment 4 Matthias Clasen 2013-04-26 13:16:25 UTC
It makes sense to me to do the same we don in the control-center, and treat the single-user case differently. For initial-setup, that means setting the system locale if we are creating a new user, but just setting the exising user's locale if we are in first-login mode.
Comment 5 Matthias Clasen 2013-04-26 15:56:17 UTC
Review of attachment 242360 [details] [review]:

The patch looks like it does exactly what I described earlier
Comment 6 Jasper St. Pierre (not reading bugmail) 2013-04-26 15:59:31 UTC
Review of attachment 242360 [details] [review]:

::: data/20-gnome-initial-setup.rules
@@ +12,2 @@
     var actionMatches = (action.id === 'org.freedesktop.udisks2.filesystem-mount-system' ||
+                         action.id == 'org.freedesktop.set-locale' ||

Use === here for consistency.

::: gnome-initial-setup/gis-driver.c
@@ +138,3 @@
+
+
+

Whitespace?

::: gnome-initial-setup/gis-driver.h
@@ +81,3 @@
+
+
+

Whitespace?

::: gnome-initial-setup/pages/language/gis-language-page.c
@@ +68,3 @@
+  g_dbus_proxy_call (priv->localed,
+                     "SetLocale",
+                     g_variant_new ("(asb)", b, TRUE),

g_variant_new_parsed ("([%s], true)", s); ?

@@ +122,3 @@
+  user = act_user_manager_get_user (act_user_manager_get_default (),
+                                    g_get_user_name ());
+  act_user_set_language (user, priv->new_locale_id);

Shouldn't this go in an existing user mode branch?
Comment 7 Michael Wood 2013-04-26 16:38:31 UTC
Push as discussed with whitespace fixes and .rules fixes

We're going to keep the g_variant stuff to be consistent with g-c-c and the setting the g-i-s user's language is fine as it won't do any harm and may be picked up by other processes.



9e4f72d0da38d10d21bd3fef5845c3d17767c666
Comment 8 Colin Walters 2013-04-30 12:56:41 UTC
Created attachment 242907 [details] [review]
0001-language-Ensure-accountsservice-is-initialized-befor.patch

I needed this patch to make it work.
Comment 9 Michael Wood 2013-04-30 14:23:36 UTC
Created attachment 242920 [details] [review]
language: Ensure accountsservice is initialized

Thanks, I realised I was testing this page when the g-c-c was open on the region page which initialised accountservice, doh.

Would it be better to connect to the user is-loaded rather than the manager?
Comment 10 Colin Walters 2013-04-30 14:32:05 UTC
Review of attachment 242920 [details] [review]:

Hm, yeah this is better than my patch.