/srv/irclogs.ubuntu.com/2017/02/22/#ubuntu-app-devel.txt

=== chihchun_afk is now known as chihchun
=== chihchun is now known as chihchun_afk
=== JanC_ is now known as JanC
=== chihchun_afk is now known as chihchun
=== chihchun is now known as chihchun_afk
=== chihchun_afk is now known as chihchun
kalikiana_renatu: Did you have a chance to test https://code.launchpad.net/~ubuntu-sdk-team/ubuntu-ui-toolkit/organizedCrime/+merge/316825 at this point?08:46
=== chihchun is now known as chihchun_afk
dakerkalikiana_: hi i started working on the iconprovider, i faced a wired issue QGuiApplication::layoutDirection() is always Qt::LeftToRight10:52
dakers/wired/weird10:52
kalikiana_daker: Are you setting it in your application?11:02
dakerkalikiana_: how ? i am just using the gallery rtl/ltr action to change the layout11:03
kalikiana_Oh. And the value stays the same?11:04
dakerwell always Qt::LeftToRight11:04
dakerso i am not sure the rtl changes are only applied to the elements not the app11:05
dakerif*11:05
kalikiana_daker: Hmmmm I'm checking examples/ubuntu-ui-toolkit-gallery/ubuntu-ui-toolkit-gallery.qml it looks like it's never actually changing it11:06
kalikiana_That should probably be changed11:07
dakerthat's what i thought11:07
dakerkalikiana_: should i file a bug ?11:09
kalikiana_daker: Yeah11:10
dakerkalikiana_: can you look at this solution https://paste.ubuntu.com/24046050/11:43
dakerthe change needs to be made in src/UbuntuToolkit/unitythemeiconprovider.cpp not src/UbuntuToolkit/ucscalingimageprovider.cpp11:44
kalikiana_daker: Note on style, braces should cuddle ie. "if (QGuiApplication::layoutDirection() == Qt::RightToLeft) {" with the opening brace on the same line11:53
dakerkalikiana_: sure11:54
kalikiana_I think that change makes sense, yeah. The check for -rtl is only needed once, right?11:54
kalikiana_As long as all code goes through that11:54
kalikiana_Seems like it will11:55
dakeryes if we are in RTL change if we have -rtl icon, if the theme found one we are good it will be returned, else the code will continue normally like it did before11:55
kalikiana_Okay11:56
kalikiana_And it won't try to be too smart, which I think is good11:56
dakeryes11:57
dakerkalikiana_: not that the only thing i have added is https://paste.ubuntu.com/24046132/11:59
dakernote*11:59
kalikiana_daker: Understood, I checked the code in unitythemingprovider.cpp to see where function was used (my main question was if it was always used to find the name)12:01
kalikiana_daker: Bug 1666869 is about the gallery, right? Or are you saying the value in any application is wrong at startup?12:02
ubot5bug 1666869 in ubuntu-ui-toolkit (Ubuntu) "QGuiApplication::layoutDirection() is always Qt::LeftToRight" [Undecided,New] https://launchpad.net/bugs/166686912:02
kalikiana_The description is a bit unclear12:04
dakerkalikiana_: no not the gallery, but the sdk, how can you force QGuiApplication::layoutDirection() to change from QML ?12:04
kalikiana_daker: So layoutDirection is wrong regardless of locale?12:04
kalikiana_Default value and changing are two different things12:05
dakerkalikiana_: wait, QGuiApplication::layoutDirection() is related to the locale ? so the "change layout" is not related to it right ?12:05
daker"change layout" button on the gallery*12:06
kalikiana_daker: The button in the gallery to change it exists for testing only. So that one doesn't need to change the locale and can see differences easily.12:06
kalikiana_At startup it should be whatever the locale says12:07
dakeri see, so how can run the gallery(for ex) with a different locale ?12:08
dakeri think i need to add LANG=$LANG to tests/Gallery/gallery to see if it works12:11
kalikiana_daker: LANGUAGE=en12:12
kalikiana_But note that this only works if it's installed12:12
kalikiana_gettext kinda sucks that way, there's no easy option for using locales from the build folder12:12
dakeryes i have 3 locales installed fr/en/ar12:12
kalikiana_So using ar or en you should see a different layout by default12:13
kalikiana_daker: FYI I updated the title of bug 166686912:14
ubot5bug 1666869 in ubuntu-ui-toolkit (Ubuntu) "Toolkit gallery doesn't change QGuiApplication::layoutDirection" [Undecided,Confirmed] https://launchpad.net/bugs/166686912:14
renatukalikiana_, I could not test it yet. Messaging app build is broken12:15
dakerkalikiana_: i'll test it, if QGuiApplication::layoutDirection change i'll just mark that bug as invalid12:15
kalikiana_daker: The bug is not invalid IF we're talking about the bug in the gallery :-)12:16
kalikiana_Again, two different things12:16
kalikiana_Easy to confuse12:16
kalikiana_renatu: You did not test, but it is broken? I don't get it12:16
renatukalikiana_, I need the new messaging-app to test it, but the build of it is broken12:17
kalikiana_renatu: Oh, unrelated issue. Okay.12:17
renatukalikiana_, because of that I could not test it12:17
kalikiana_renatu: Understood.12:17
dakerkalikiana_: that "change layout" button on the gallery does change the layout but not QGuiApplication::layoutDirection12:21
kalikiana_daker: Yes12:22
dakerkalikiana_: it should ?12:22
dakerbecause that's the bug i have filed12:22
kalikiana_daker: I think the button should change the layout :-)12:39
dakerbut not QGuiApplication::layoutDirection, right ? if yes then the bug is invalid...12:39
=== _salem is now known as salem_
dakerah i think i understand what you mean there, you mean even if you pass LANGUAGE=ar QGuiApplication::layoutDirection stays Qt::LeftToRight12:43
kalikiana_that would be a different bug13:03
dakerkalikiana_: would you mind explaining it ?13:54
kalikiana_daker: First bug: you run the gallery. The gallery has a button, for testing purposes, to switch between RTL and LTR, regardless of what locale you're using. Turns out, the switch is incomplete. the layout direction of QGuiApplication is not changing, only the QML layout changes15:01
dakerkalikiana_: this is what i meant when i reported the bug15:03
kalikiana_daker: Second - maybe - bug, you run any app in different locales, which are written from LTR or RTL by default, layout direction of QGuiApplication should take the default from the locale, eg. English is LTR, Arabic is RTL, Japanese is LTR for the purposes of a computer screen15:04
dakerkalikiana_: ok, this one i still need to test it15:06
dakerkalikiana_: should i open another bug for the icon provider or use the same bug 1665938 ?15:20
ubot5bug 1665938 in ubuntu-ui-toolkit (Ubuntu) "Pagestack backAction should point to the right in RTL" [Undecided,Confirmed] https://launchpad.net/bugs/166593815:20
kalikiana_daker: I'd say renaming the bug is fine15:24
renatukalikiana_, you need to rebuild the silo, there is a new version of UITK on overlay-ppa17:46
=== salem_ is now known as _salem
dakerkalikiana_: ha ha, the second i am suspecting it's also a bug :D22:44

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!