Re: Testing several plasmoid instances at the same time

2012-10-25 Thread Aaron J. Seigo
On Wednesday, October 24, 2012 22:25:12 Michał 'rysiek'  Woźniak wrote:
 Hi there,

 I am writing a plasmoid that is supposed to have drag and drop support
 - but am unable to test it efficiently with plasmoidviewer, as I have
 not found a way to display several instances of the same plasmoid in
 the same containment so that I could drag and drop between them.

 Any hints? Am I missing something?

nope :)

perhaps you could try the widget-strip app from plasma-mobile?

--
Aaron J. Seigo

signature.asc
Description: This is a digitally signed message part.
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix KRunner's 'spell in foreign language' feature

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106244/#review20838
---


just some whitespace and code style issues to address; the patch logic itself 
looks good.


runners/spellchecker/spellcheck.h
http://git.reviewboard.kde.org/r/106244/#comment16452

m_spellers and m_spellLock



runners/spellchecker/spellcheck.h
http://git.reviewboard.kde.org/r/106244/#comment16451

this should be above the data members



runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16446

coding style: comments go inside the branch, braces with 'else if' on the 
same line.. e.g.:

} else if {
// if the family is english, default to en_US



runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16447

see above :)



runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16448

see above :)



runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16450

1_speller is a really odd var name, and doesn't really say much about what 
it does. just speller should be good enough.



runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16449

missing whitespace: if (1_speller-isValid()) {


- Aaron J. Seigo


On Sept. 21, 2012, 1:51 p.m., Simeon Bird wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106244/
 ---
 
 (Updated Sept. 21, 2012, 1:51 p.m.)
 
 
 Review request for Plasma, Sebastian Kügler and Matthias Fuchs.
 
 
 Description
 ---
 
 Krunner's spellcheck plugin has been broken since 
 bd291d21f096a714a171e7af3a534ba345ca5659 (about two years ago) because it 
 called Sonnet::Speller::setLanguage every time the spellchecker was invoked, 
 which was not thread-safe. 
 This diff fixes the segfaults, and the feature, which I understand to be, 
 basically, the ability to type 'spell french bonjour' and have it check the 
 spelling.
 
 The current code simply calls setLanguage on the second term in the search 
 query, and then checks whether the resulting dictionary object is valid. The 
 spell-checker expects languages like 'fr_FR' or 'French (France)' which the 
 user was unlikely to type in correctly (at least, I never figured it out 
 until I read the source). 
 
 Instead, this patch create a new spell-check object (the creation is guarded 
 by a mutex) when a new language is used (thus never needing to call 
 setLanguage). Future queries use the already created speller for the new 
 language, and spellers are deleted on the teardown() signal. 
 
 We make a map between the speller codes and simple natural language language 
 names in init(); this is a little bit tricky, because languages have 
 sub-variants. My approach was to try and find the main language of the group: 
 so 'french' gets you fr_FR.  For english I defaulted to US english. 
 
 I have not tested this spelling an asian language as I don't speak one.
 
 I have not implemented 'spell canadian french' or similar. If you want a 
 specific sublanguage you have to type in the language code directly.
 
 
 This addresses bugs 264779 and 303831.
 http://bugs.kde.org/show_bug.cgi?id=264779
 http://bugs.kde.org/show_bug.cgi?id=303831
 
 
 Diffs
 -
 
   runners/spellchecker/spellcheck.h 492c370 
   runners/spellchecker/spellcheck.cpp 672732d 
 
 Diff: http://git.reviewboard.kde.org/r/106244/diff/
 
 
 Testing
 ---
 
 Compiled, installed, ran for a week and spell-checked a bunch of things in 
 European languages.
 
 
 Thanks,
 
 Simeon Bird
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix screenChanged signal in javascript appletinterface

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106936/#review20841
---

Ship it!


Ship It!

- Aaron J. Seigo


On Oct. 18, 2012, 1 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106936/
 ---
 
 (Updated Oct. 18, 2012, 1 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Signal/slot signatures were wrong. Correctly forward the screenChanged 
 signal. This removes the following warning for me when running a QML 
 containment in plasmoidviewer:
 
 Object::connect: No such slot ContainmentInterface::screenChanged() in 
 /home/sebas/kdesvn/src/kde/kde-runtime/plasma/scriptengines/javascript/plasmoid/appletinterface.cpp:605
 
 
 Diffs
 -
 
   plasma/scriptengines/javascript/plasmoid/appletinterface.cpp f2ccf61 
 
 Diff: http://git.reviewboard.kde.org/r/106936/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix ReferenceErrors in ListItem

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106937/#review20842
---

Ship it!


Ship It!

- Aaron J. Seigo


On Oct. 18, 2012, 2:39 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106937/
 ---
 
 (Updated Oct. 18, 2012, 2:39 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Check if referenced objects are valid
 
 This kills two ReferenceErrors I'm seeing when using ListItems inside
 VisualItemModels (in this case, there's no view and visual parent
 attached on creation).
 
 
 Diffs
 -
 
   plasma/declarativeimports/plasmacomponents/qml/ListItem.qml e352eb0 
 
 Diff: http://git.reviewboard.kde.org/r/106937/diff/
 
 
 Testing
 ---
 
 tried the news app and widgetgallery, no regressions seen.
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: make kickoff-qml partly c++, restores simpleapplet, applet type switch

2012-10-25 Thread Aaron J. Seigo


 On Oct. 19, 2012, 3:09 p.m., Greg T wrote:
  looks good, just a couple of notes:
  why are you installing 2 desktop files for the kickoff launcher:
  - metadata.desktop and the old plasma-applet-launcher.desktop
  - we don't need CMakeLists.txt in core/ anymore?
  - also it conflicts with my last commit in kickoff-qml (just a minor in 
  kickoff.qml)
 
 Marco Martin wrote:
 yep, 2 desktop files get installed unfortunately, is used in the hybrid 
 plasmoids, don't see much alternative unfortunately.
 luckily metadata.desktop is local in the package so doesn't go to pollute 
 the syscoca db
 
 i resolved the conflict and removed the other files besides cmakefile in 
 core
 (pretty much all of ui/ and the config stuff in the package)

the solution to the 2 .desktop files is to make a policy for c++ plasmoids that 
automatically associates a qml package matching their c++ pluginName with them.


- Aaron J.


---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106947/#review20575
---


On Oct. 19, 2012, 1:04 p.m., Marco Martin wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106947/
 ---
 
 (Updated Oct. 19, 2012, 1:04 p.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 this makes the simple laucher work again, and since kickoff is in part c++, 
 the menu editor option as well as the switch from kickoff to classic works 
 again.
 
 main reason of this tough is to eliminate the org.kde.kickoff import, that 
 shouldn't be public api
 
 
 Diffs
 -
 
   plasma/desktop/applets/kickoff/CMakeLists.txt 4f61700 
   plasma/desktop/applets/kickoff/applet/applet.h f3afe73 
   plasma/desktop/applets/kickoff/applet/applet.cpp a6f7379 
   plasma/desktop/applets/kickoff/package/contents/ui/KickoffItem.qml 4d0e218 
   plasma/desktop/applets/kickoff/package/contents/ui/kickoff.qml f953565 
   plasma/desktop/applets/kickoff/package/metadata.desktop 9cb997d 
   plasma/desktop/applets/kickoff/simpleapplet/menuview.cpp 963c18b 
   plasma/desktop/applets/kickoff/simpleapplet/simpleapplet.cpp 28fba18 
 
 Diff: http://git.reviewboard.kde.org/r/106947/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Marco Martin
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Testing several plasmoid instances at the same time

2012-10-25 Thread Giorgos Tsiapaliokas
On 25 October 2012 11:47, Aaron J. Seigo ase...@kde.org wrote:

 On Wednesday, October 24, 2012 22:25:12 Michał 'rysiek'  Woźniak wrote:
  Hi there,
 
  I am writing a plasmoid that is supposed to have drag and drop support
  - but am unable to test it efficiently with plasmoidviewer, as I have
  not found a way to display several instances of the same plasmoid in
  the same containment so that I could drag and drop between them.
 
  Any hints? Am I missing something?


have you tried to open plasma-desktop with
Xephyrhttp://techbase.kde.org/Archive:Getting_Started/Run/Nested_Session
?

Regards,
Giorgos

-- 
Giorgos Tsiapaliokas (terietor)
KDE Developer

terietor.gr
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix Inconsistencies and Bugs in Activity Bar's Size Hinting

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106978/#review20847
---


there are a number of style issues with this patch, but the real problem is 
setting it to a hardcoded 1/3rd of the panel.

i would suggest that the real underlying problem here is that the m_tabBar 
sizehint keeps changing so radically.


plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16453

this should be a member of the class (the hint should have been passing in 
*this constantly); perhaps call it 'calculatePreferredSize to avoid 
conflicting with setPreferredSize



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16455

1/3rd looks wrong and is going to give incorrect results in several 
situations (e.g. when pref size of all plasmoids fit, but the activity bar has 
fewer buttons than the space it is alloted)



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16454

in these cases, pref size should be set to 
m_tabBar-nativeWidget()-sizeHint()



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16458

this belongs in constraintsEvent, not here.



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16461

this should never be used as it assumes all sorts of things that not 
guaranteed at all, e.g. that the applets in the panel are laid out linearly 
with respect to each other.



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16460

and for non-horz/vert? remember that it can be moved between form factors :)



plasma/generic/applets/activitybar/activitybar.cpp
http://git.reviewboard.kde.org/r/106978/#comment16459

should be on same line: } else {


- Aaron J. Seigo


On Oct. 22, 2012, 2:27 a.m., David Narváez wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106978/
 ---
 
 (Updated Oct. 22, 2012, 2:27 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 The main issue was caused by the fact that asking the tab bar native widget 
 to provide a size hint was giving a different size every time which caused 
 the activity bar to expand or shrink in the presence of another expanding 
 widget (in my case, the taskbar), so this patch decides a size hint from the 
 size of the containment (one third of the width of height depending on the 
 form factor) but the size policy is set to expand when the activity bar is 
 the only widget in the containment.
 
 
 This addresses bug 225078.
 http://bugs.kde.org/show_bug.cgi?id=225078
 
 
 Diffs
 -
 
   plasma/generic/applets/activitybar/activitybar.cpp e66bf04 
 
 Diff: http://git.reviewboard.kde.org/r/106978/diff/
 
 
 Testing
 ---
 
 1) Add a panel with an actyivity bar and a task bar
 2) Add a panel with an activty bar only
 3) Change activities
 
 Before this patch, the activity bar in the panel with a task bar shrinks or 
 enlarges with every activity change; while the size of the activity bar in 
 the second panel remains constant. After this patch, the size of the activity 
 bar in both panels remains constant.
 
 
 Thanks,
 
 David Narváez
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Possibility to change an element ID of svg image in IconWidget

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/107017/#review20863
---


the real fix here is to not use IconWidget :) that's a QGraphicsWidget thing 
and will need to be replaced eventually anyways.

this should be using the Button QML element, which does support using SVG 
files. 

- Aaron J. Seigo


On Oct. 24, 2012, 1:02 p.m., Dmitry Ashkadov wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/107017/
 ---
 
 (Updated Oct. 24, 2012, 1:02 p.m.)
 
 
 Review request for kdelibs and Plasma.
 
 
 Description
 ---
 
 New System tray uses IconWidget QML item, but it isn't possible to set svg 
 image with specified element id. Now I use Svg QML item to load svg and then 
 pass icon to IconWidget, moreover svg is converted to pixmap (: . At the same 
 time IconWidget can handle svg images, so these small changes make me happy 
 :) because I will can eliminate usage of Svg QML items for arrow and Dbus 
 tasks in system tray. 
 
 
 Diffs
 -
 
   plasma/widgets/iconwidget.h 78f392e 
   plasma/widgets/iconwidget.cpp a2092a4 
 
 Diff: http://git.reviewboard.kde.org/r/107017/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Dmitry Ashkadov
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Stackfolder inclusion to 4.10 [attempt#2]

2012-10-25 Thread Ural Mullabaev
Hi Andreas!

 Much more readable now, great. Still it should obey the theme text
 color which
 is black instead of while. See sebas suggestion:
I set color for text from theme. And I detected black font with shadow too dark 
on the light background. I had to switch off shadows.

 Another feature suggestion: It would be utterly cool to start typing
 and
 filter the files like e.g. the Takeoff plasmoid does:
 http://kde-apps.org/content/show.php?content=144078
Good idea! But I think it's too late to implement now, we'll consider to the 
next development cycle
Funny, we have applet SimpleWelcome look like this)

Regards,
Ural Mullabaev
Rosa Laboratory
www.rosalab.com
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Possibility to change an element ID of svg image in IconWidget

2012-10-25 Thread Dmitry Ashkadov


 On Oct. 25, 2012, 11:36 a.m., Aaron J. Seigo wrote:
  the real fix here is to not use IconWidget :) that's a QGraphicsWidget 
  thing and will need to be replaced eventually anyways.
  
  this should be using the Button QML element, which does support using SVG 
  files.

IconWidget supports QAction so it's possible to handle global shortcuts. Does 
QML Button support QAction? Or is is another way to handle global shortcuts 
from QML?


- Dmitry


---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/107017/#review20863
---


On Oct. 24, 2012, 1:02 p.m., Dmitry Ashkadov wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/107017/
 ---
 
 (Updated Oct. 24, 2012, 1:02 p.m.)
 
 
 Review request for kdelibs and Plasma.
 
 
 Description
 ---
 
 New System tray uses IconWidget QML item, but it isn't possible to set svg 
 image with specified element id. Now I use Svg QML item to load svg and then 
 pass icon to IconWidget, moreover svg is converted to pixmap (: . At the same 
 time IconWidget can handle svg images, so these small changes make me happy 
 :) because I will can eliminate usage of Svg QML items for arrow and Dbus 
 tasks in system tray. 
 
 
 Diffs
 -
 
   plasma/widgets/iconwidget.h 78f392e 
   plasma/widgets/iconwidget.cpp a2092a4 
 
 Diff: http://git.reviewboard.kde.org/r/107017/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Dmitry Ashkadov
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix ReferenceErrors in ListItem

2012-10-25 Thread Commit Hook

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106937/#review20871
---


This review has been submitted with commit 
602968b41655fdefba053d6aa32b505f98713dea by Sebastian Kügler to branch master.

- Commit Hook


On Oct. 18, 2012, 2:39 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106937/
 ---
 
 (Updated Oct. 18, 2012, 2:39 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Check if referenced objects are valid
 
 This kills two ReferenceErrors I'm seeing when using ListItems inside
 VisualItemModels (in this case, there's no view and visual parent
 attached on creation).
 
 
 Diffs
 -
 
   plasma/declarativeimports/plasmacomponents/qml/ListItem.qml e352eb0 
 
 Diff: http://git.reviewboard.kde.org/r/106937/diff/
 
 
 Testing
 ---
 
 tried the news app and widgetgallery, no regressions seen.
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix screenChanged signal in javascript appletinterface

2012-10-25 Thread Commit Hook

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106936/#review20872
---


This review has been submitted with commit 
42a30676af53614da0c98156386120a65cd9d504 by Sebastian Kügler to branch master.

- Commit Hook


On Oct. 18, 2012, 1 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106936/
 ---
 
 (Updated Oct. 18, 2012, 1 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Signal/slot signatures were wrong. Correctly forward the screenChanged 
 signal. This removes the following warning for me when running a QML 
 containment in plasmoidviewer:
 
 Object::connect: No such slot ContainmentInterface::screenChanged() in 
 /home/sebas/kdesvn/src/kde/kde-runtime/plasma/scriptengines/javascript/plasmoid/appletinterface.cpp:605
 
 
 Diffs
 -
 
   plasma/scriptengines/javascript/plasmoid/appletinterface.cpp f2ccf61 
 
 Diff: http://git.reviewboard.kde.org/r/106936/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix screenChanged signal in javascript appletinterface

2012-10-25 Thread Commit Hook

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106936/#review20873
---


This review has been submitted with commit 
51398decee51459120d1610e372c3f8dc40fe17a by Sebastian Kügler to branch KDE/4.9.

- Commit Hook


On Oct. 18, 2012, 1 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106936/
 ---
 
 (Updated Oct. 18, 2012, 1 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Signal/slot signatures were wrong. Correctly forward the screenChanged 
 signal. This removes the following warning for me when running a QML 
 containment in plasmoidviewer:
 
 Object::connect: No such slot ContainmentInterface::screenChanged() in 
 /home/sebas/kdesvn/src/kde/kde-runtime/plasma/scriptengines/javascript/plasmoid/appletinterface.cpp:605
 
 
 Diffs
 -
 
   plasma/scriptengines/javascript/plasmoid/appletinterface.cpp f2ccf61 
 
 Diff: http://git.reviewboard.kde.org/r/106936/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix ReferenceErrors in ListItem

2012-10-25 Thread Commit Hook

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106937/#review20874
---


This review has been submitted with commit 
6fe8ee6ed91ac087177760990da63b1a8e5f6de4 by Sebastian Kügler to branch KDE/4.9.

- Commit Hook


On Oct. 18, 2012, 2:39 a.m., Sebastian Kügler wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106937/
 ---
 
 (Updated Oct. 18, 2012, 2:39 a.m.)
 
 
 Review request for Plasma.
 
 
 Description
 ---
 
 Check if referenced objects are valid
 
 This kills two ReferenceErrors I'm seeing when using ListItems inside
 VisualItemModels (in this case, there's no view and visual parent
 attached on creation).
 
 
 Diffs
 -
 
   plasma/declarativeimports/plasmacomponents/qml/ListItem.qml e352eb0 
 
 Diff: http://git.reviewboard.kde.org/r/106937/diff/
 
 
 Testing
 ---
 
 tried the news app and widgetgallery, no regressions seen.
 
 
 Thanks,
 
 Sebastian Kügler
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: Review Request: Fix KRunner's 'spell in foreign language' feature

2012-10-25 Thread Aaron J. Seigo

---
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106244/#review20913
---

Ship it!


i've fixed the bug being worked around as noted below, but otherwise looks 
clean now ... cheers :)


runners/spellchecker/spellcheck.cpp
http://git.reviewboard.kde.org/r/106244/#comment16474

that would actually be a bug. prepare() should _always_ be called...

i see why this is happening: a bug in 
RunnerManagerPrivate::loadInstalledRunner. this is now fixed in kdelibs rev 
28a310b which should make this code unnecessary.


- Aaron J. Seigo


On Oct. 25, 2012, 5:24 p.m., Simeon Bird wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 http://git.reviewboard.kde.org/r/106244/
 ---
 
 (Updated Oct. 25, 2012, 5:24 p.m.)
 
 
 Review request for Plasma, Sebastian Kügler and Matthias Fuchs.
 
 
 Description
 ---
 
 Krunner's spellcheck plugin has been broken since 
 bd291d21f096a714a171e7af3a534ba345ca5659 (about two years ago) because it 
 called Sonnet::Speller::setLanguage every time the spellchecker was invoked, 
 which was not thread-safe. 
 This diff fixes the segfaults, and the feature, which I understand to be, 
 basically, the ability to type 'spell french bonjour' and have it check the 
 spelling.
 
 The current code simply calls setLanguage on the second term in the search 
 query, and then checks whether the resulting dictionary object is valid. The 
 spell-checker expects languages like 'fr_FR' or 'French (France)' which the 
 user was unlikely to type in correctly (at least, I never figured it out 
 until I read the source). 
 
 Instead, this patch create a new spell-check object (the creation is guarded 
 by a mutex) when a new language is used (thus never needing to call 
 setLanguage). Future queries use the already created speller for the new 
 language, and spellers are deleted on the teardown() signal. 
 
 We make a map between the speller codes and simple natural language language 
 names in init(); this is a little bit tricky, because languages have 
 sub-variants. My approach was to try and find the main language of the group: 
 so 'french' gets you fr_FR.  For english I defaulted to US english. 
 
 I have not tested this spelling an asian language as I don't speak one.
 
 I have not implemented 'spell canadian french' or similar. If you want a 
 specific sublanguage you have to type in the language code directly.
 
 
 This addresses bugs 264779 and 303831.
 http://bugs.kde.org/show_bug.cgi?id=264779
 http://bugs.kde.org/show_bug.cgi?id=303831
 
 
 Diffs
 -
 
   runners/spellchecker/spellcheck.h 492c370 
   runners/spellchecker/spellcheck.cpp 672732d 
 
 Diff: http://git.reviewboard.kde.org/r/106244/diff/
 
 
 Testing
 ---
 
 Compiled, installed, ran for a week and spell-checked a bunch of things in 
 European languages.
 
 
 Thanks,
 
 Simeon Bird
 


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


qml systemtray: small refactorings

2012-10-25 Thread Aaron J. Seigo
hi...

i suppose this is mostly for Dmitry, but its nice to have these discussions 
here :)

so .. system tray plasmoid. works pretty well it seems. :)

started looking through the code a bit more deeply and i think we can start to 
tighten it up a bit.

for example, it seems that TasksPool duplicates Manager. the only thing 
TasksPool really adds is a QVariantHash and access to the host applet. this 
probably could just be a QHashQString, QObject* though (skipping all the 
QVariant overhead) and added to Manager.

to have this hash work in the QML, it is probably necessary to do sth like:

namespace SystemTray {
 typedef QHashQString, QObject * ObjectHash;
}
Q_DECLARE_METATYPE(SystemTray::ObjectHash)
qRegisterMetaTypeSystemTray::ObjectHash(ObjectHash)

that should hopefully let it work via QVariant properly. (the first 3 lines go 
into headers, the 3 line into C++ somewhere)

UiTask is also ripe for some refactoring, as it's really just a proxy for 
Task. the TaskType enum should go into Task itself, and a QString id() const 
method should be added to Task as well. that really just leaves how to get at 
the host applet pointer so that the widget can be retrieved.

the applet pointer could be made available to the QML and then WidgetItem 
could have an applet (or host?) property which it would use to derive its 
widget().

then TasksPool is not needed for the host applet pointer. UiTask becomes just 
Task, and Manager can be used directly instead of TasksPool in the QML.

something else I don't quite understand from the code is why QObjects, which 
import into QML just fine, are turned in QVariants everywhere before being sent 
into the QML?

and example is in WidgetItem:

Q_PROPERTY(QVariant widget READ widget WRITE setWidget NOTIFY 
changedWidget) /// widget to embed

all it does is return a QObject pointer.. QML *should* handle that just fine, 
and when i changed it to be just a QObject, it indeed continued to work as 
expected. (i've even pushed that change)

.. there's probably more, but this is probably a good start. what's there now 
is functional and definitely decent code to be certain; it's just nice to make 
it as smooth as possible so maintenance later is easier :)

p.s. i'd also like to get rid of all the private pimpl classes; this is not a 
library after all :)

-- 
Aaron J. Seigo

signature.asc
Description: This is a digitally signed message part.
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


re: move plasma tools to plasmate

2012-10-25 Thread Shaun Reich
(changing title as the other thread was freaking huge and a bit bikesheddy).

seems the man-plasmaenginexplorer in workspace/doc/plasma-desktop has
not been moved out, along with the tool itself in that move, tereitor,
care to fix? (i don't have that cloned)

-- 
Shaun Reich,
KDE Software Developer (kde.org)
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: qml systemtray: small refactorings

2012-10-25 Thread Dmitry Ashkadov

26.10.2012 00:43, Aaron J. Seigo пишет:

hi...

i suppose this is mostly for Dmitry, but its nice to have these discussions
here :)

so .. system tray plasmoid. works pretty well it seems. :)


Hello!

Thank you for your questions! But first of all, I'd like to know what 
branch should I use to make some refactoring/changes? As I know today 
4.10 branch must be created.


I don't understand why every task can have different widgets for 
different hosts (applets):

QHashPlasma::Applet *, QGraphicsWidget * widgetsByHost() const;

Is it really possible to have few applets in one applet?


___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


Re: qml systemtray: small refactorings

2012-10-25 Thread Luca Beltrame
In data venerdì 26 ottobre 2012 09:40:25, Dmitry Ashkadov ha scritto:

 branch should I use to make some refactoring/changes? As I know today
 4.10 branch must be created.

Today marks the *soft* feature freeze: in other words, not yet frozen for new
features, there's just a limit to new features being introduced (but these
adjustments don't qualify IMO as completely new features).

Hard feature freeze (a proper freeze, in that case) is later on. So for now I
think you can work directly in master.

--
Luca Beltrame - KDE Forums team
KDE Science supporter
GPG key ID: 6E1A4E79


signature.asc
Description: This is a digitally signed message part.
___
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel