Merge lp://staging/~fourdollars/unity-greeter/add-hidpi-support into lp://staging/unity-greeter
- add-hidpi-support
- Merge into trunk
Status: | Needs review |
---|---|
Proposed branch: | lp://staging/~fourdollars/unity-greeter/add-hidpi-support |
Merge into: | lp://staging/unity-greeter |
Diff against target: |
84 lines (+33/-12) 1 file modified
src/unity-greeter.vala (+33/-12) |
To merge this branch: | bzr merge lp://staging/~fourdollars/unity-greeter/add-hidpi-support |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Robert Ancell | Needs Information | ||
Shih-Yuan Lee (community) | Needs Information | ||
PS Jenkins bot (community) | continuous-integration | Needs Fixing | |
Review via email: mp+244266@code.staging.launchpad.net |
Commit message
Add HiDPI display support.
Description of the change
PS Jenkins bot (ps-jenkins) wrote : | # |
- 1468. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
Robert Ancell (robert-ancell) wrote : | # |
Can't this just be completed using the existing GDK API instead of using X calls?
i.e.
var use_hidpi = false;
var screen = Gdk.Screen.
for (var i = 0; i < screen.
{
var width_mm = screen.
var height_mm = screen.
var ppi = ...
if (ppp ...)
use_hidpi = true;
}
Shih-Yuan Lee (fourdollars) wrote : | # |
No, this step needs to be done before GDK initialized.
- 1469. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1470. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1471. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
Shih-Yuan Lee (fourdollars) wrote : | # |
BTW, by the internal design of GTK+3/GDK, unity-settings-
Because the xsettings plugin will bring up a property called '_XSETTINGS_
This scale factor will be changed with "gsettings get org.gnome.
The current design of unity-greeter will execute Gtk.init() or Gdk.init() before unity-settings-
If we can execute unity-settings-
- 1472. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
Robert Ancell (robert-ancell) wrote : | # |
That seems like a better solution. We should start unity-settings-
- 1473. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1474. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1475. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1476. By Robert Ancell
-
Ensure non-selected prompt boxes don't overlap adjacent boxes. This fixes a bug where you couldn't select usernames
- 1477. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1478. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1479. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1480. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1481. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1482. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1483. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1484. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1485. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1486. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1487. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1488. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1489. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1490. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1491. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1492. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1493. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1494. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1495. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
- 1496. By Launchpad Translations on behalf of unity-greeter-team
-
Launchpad automatic translations update.
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:1497
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
Shih-Yuan Lee (fourdollars) wrote : | # |
Hi,
Could you help to review my revision?
I saw the failed of jenkins, but it doesn't seem relative to my change.
Robert Ancell (robert-ancell) wrote : | # |
I don't understand the purpose of:
var builder = new StringBuilder ();
builder.append ("xwininfo -root -tree");
builder.append ("| awk '{print $1}'");
builder.append ("| grep ^0x");
builder.append ("| while read id; do xprop -id $id; done");
builder.append ("| grep _XSETTINGS_SETTINGS > /dev/null");
Why do we need to do this?
Robert Ancell (robert-ancell) wrote : | # |
Shih-Yuan Lee (fourdollars) wrote : | # |
Making https:/
It is up to Robert.
The StringBuilder is to create commands combo to check if the xsettings plugin of unity-settings-
Robert Ancell (robert-ancell) wrote : | # |
> The StringBuilder is to create commands combo to check if the xsettings plugin
> of unity-settings-
That seems really hacky - how does Unity shell tell if the xsettings plugin is active? We should use the same method,
Shih-Yuan Lee (fourdollars) wrote : | # |
So far as I know, Unity shell does nothing for the xsettings plugin.
Robert Ancell (robert-ancell) wrote : | # |
Looking at unity-settings-
static void
name_acquired_
{
GDBusProxy *proxy;
proxy = gnome_settings_
#ifdef HAVE_IBUS
#endif
}
And in unity-greeter/
[DBus (name="
public class SessionManagerI
{
public bool session_is_active { get { return true; } }
public string session_name { get { return "ubuntu"; } }
public uint32 inhibited_actions { get { return 0; } }
}
So I think you should be able to add a register_client method and wait for "gnome-
Robert Ancell (robert-ancell) wrote : | # |
I think for Unity shell it's probably managed in gnome-session (i.e. the shell doesn't start until gnome-session has gnome-settings-
Shih-Yuan Lee (fourdollars) wrote : | # |
Even unity-settings-
Is there any way to check if the xsettings plugin is ready directly?
Robert Ancell (robert-ancell) wrote : | # |
I don't know of a method for this, but:
- Does this mean there's a race condition if you start a GTK+ application in Unity before the xsettings plugin is ready? And we only see this in the greeter because we start quickly?
- Do we need to wait for the plugin? Shouldn't GTK+ detect when this setting appears/changes and adjust appropriately?
Shih-Yuan Lee (fourdollars) wrote : | # |
- Yes, there is a race condition. We also see this issue in another bug #1382291.
- GTK+ will detect _XSETTINGS_SETTINGS in the first function call relative to the graphics. If it can not find _XSETTINGS_
- 1497. By Shih-Yuan Lee
-
Waiting for the xsettings plugin of unity-settings-
daemon. (LP: #1286878)
Robert Ancell (robert-ancell) wrote : | # |
The problem with this branch is the hack calling xwininfo from the the greeter before starting. This is risky because:
- We're calling a relatively complicated shell script from inside an executable (very hard to understand)
- We're blocking startup for this to complete (if something goes wrong we have no UI)
The changes without this hack will be accepted, then it might be easier to do a second MP to solve the race condition.
Sebastien Bacher (seb128) wrote : | # |
@Shih-Yuan Lee, are we sure about the "the xsettings needs to be set before GTK starts"?
I just did that test
- start a wmaker session
- run gedit
- run unity-settings-
- change the scaling-factor gsettings key
gedit scaled fine, obviously it was started before having a settings manager...
(that's on vivid)
Sebastien Bacher (seb128) wrote : | # |
should that be rejected? the greeter correctly scale now in vivid with unity-settings-
Shih-Yuan Lee (fourdollars) wrote : | # |
@seb128,
I believe there is some improvement for the GTK+2/GTK+3 in vivid so we may not need this in vivid.
Unmerged revisions
- 1497. By Shih-Yuan Lee
-
Waiting for the xsettings plugin of unity-settings-
daemon. (LP: #1286878)
FAILED: Continuous integration, rev:1468 /code.launchpad .net/~fourdolla rs/unity- greeter/ add-hidpi- support/ +merge/ 244266/ +edit-commit- message
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https:/
http:// jenkins. qa.ubuntu. com/job/ unity-greeter- ci/55/ jenkins. qa.ubuntu. com/job/ unity-greeter- vivid-amd64- ci/3 jenkins. qa.ubuntu. com/job/ unity-greeter- vivid-armhf- ci/3
Executed test runs:
SUCCESS: http://
SUCCESS: http://
Click here to trigger a rebuild: s-jenkins. ubuntu- ci:8080/ job/unity- greeter- ci/55/rebuild
http://