Commit Graph

326 Commits

Author SHA1 Message Date
Jason Stubbs
10af4df668 Added methods for gaining information about the view. This is useful for
applets such as systemtray and tasks that need to know about global
geometry.

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=746172
2007-12-08 03:35:11 +00:00
Jason Stubbs
89a387b76d Cast the parent being checked rather than parentItem()
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=743922
2007-12-02 11:19:26 +00:00
Aaron J. Seigo
9d936d1d8f still messed up, but less useless confusing code in there now =)
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=743202
2007-11-30 01:06:27 +00:00
Aaron J. Seigo
312f42dec0 when setting min/max sizes, adjust our geometry if our current size is not within those boundaries
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=742716
2007-11-28 18:41:21 +00:00
Aaron J. Seigo
0374286c07 * don't reset the painter's opacity to the widget's opacity; rather, *apply* the widget's opacity to the painter's opacity
* get rid of the internal child list. we don't need it and it's a pain (as in error prone) to maintain, esp when we have QGraphicsItem::children()

(man i wish svn allows partial file commits =/ i wonder (idly) if git or any of those new fangled vcs's do?)

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=742100
2007-11-27 06:03:19 +00:00
Tom Albers
bd382fa983 Fix wording so it does not result in false positives.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=741335
2007-11-25 13:28:25 +00:00
Matias Valdenegro Toro
6c5aea1f60 Add license header to label.cpp
Remove "at your option" from label.h

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=740756
2007-11-24 02:45:34 +00:00
Seb Ruiz
d6001be92a warning fixes
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=739904
2007-11-22 07:19:43 +00:00
Aaron J. Seigo
65d405f264 more layouting love;
* widgets should let Widget handle sizing, geometry unless there are very good reasons for it
* don't relayout the parent layout if the parent layout is already relayouting, because that relayout will have called the child's relayout in the first place. get it? relayout!
* i can dance. we can dance. do the relayout dance.
* some style guide fixes

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738957
2007-11-20 01:19:59 +00:00
Aaron J. Seigo
396a48d6ce don't implement your own min/max size like this
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738952
2007-11-20 01:00:06 +00:00
Aaron J. Seigo
e614df56d0 * consolidate geometry() and setGeometry() from the layouts into Layout
* introduce relayout() which does only that
* place guards around relayout() calls in Layout class to prevent recursion

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738923
2007-11-19 23:45:56 +00:00
Alexis Ménard
ff0b3da511 Fix include for layout
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738921
2007-11-19 23:40:03 +00:00
Alexis Ménard
55d04002f7 Fix setSize now protected
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738909
2007-11-19 23:16:22 +00:00
Aaron J. Seigo
92ba2c1b0b move all the layouts to their own directory; much more logical and makes it easier to not miss layouts that need changes
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738898
2007-11-19 22:42:56 +00:00
Aaron J. Seigo
26098964a9 some basic guards; much, much more to follow but first must move files around
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738887
2007-11-19 22:24:18 +00:00
Aaron J. Seigo
9b25961432 code defensively so that items can't be double added to layouts. i love the class design here that makes me duplicate code all over =(((
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738877
2007-11-19 22:04:30 +00:00
Aaron J. Seigo
364b0dca90 minor cleanups and better use of convenience api's
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738770
2007-11-19 16:37:46 +00:00
Aaron J. Seigo
6124183a72 move the blur.cpp into the #define as we don't even really use it right now
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738753
2007-11-19 15:40:55 +00:00
Dirk Mueller
7348a68f3c these two are no longer implemented
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738682
2007-11-19 13:01:43 +00:00
Aaron J. Seigo
d4438218f4 don't manage our own size, use the facilities in Widget
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738576
2007-11-19 07:57:04 +00:00
Aaron J. Seigo
1a3aec4af2 add another setSize convenience method and use d->size more consistently internally for clarity
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738568
2007-11-19 07:53:48 +00:00
Aaron J. Seigo
78293fea45 always return something, well, even though we always would have. g++ isn't *that* smart ;)
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738560
2007-11-19 07:40:25 +00:00
Aaron J. Seigo
0006ce0ec4 introduce per-side margins to layouts. you can still just call setMargin(qreal) if you wish, but now this is much more useful for, say, panels.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738526
2007-11-19 03:30:24 +00:00
Aaron J. Seigo
86d745a644 get rid of the crash for now
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738319
2007-11-18 16:24:38 +00:00
Aaron J. Seigo
1dae9bba86 SVN_SILENT: misc ws fixes
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738072
2007-11-17 21:42:36 +00:00
Aaron J. Seigo
2f5fa3f5fa remove items that are removed from us from our layout, as well
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738068
2007-11-17 21:32:21 +00:00
Aaron J. Seigo
d9493e73ef avoid unecessary updates, use d->size consistently so problem, if they arise, show up more consistently ;)
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738038
2007-11-17 19:01:02 +00:00
Aaron J. Seigo
e5dca92fdf always use the parent's geometry when available and stop keeping track of our own geometry in FreeLayout
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=738036
2007-11-17 18:53:16 +00:00
Laurent Montel
287a5db49d SVN_SILENT: not necessary to add endl;
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=737177
2007-11-15 18:46:43 +00:00
Andre Duffeck
eabba50aa2 this may result in an endless loop and is not necessary
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=737074
2007-11-15 12:54:37 +00:00
Andre Duffeck
3b6b25445d Do not use space for text if there is none set
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=736901
2007-11-15 06:59:25 +00:00
Aaron J. Seigo
ce765ec610 better button mouse interaction; patch by Jason Stubbs
CCMAIL:jasonstubbs@gmail.com

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=736872
2007-11-15 03:35:12 +00:00
Andre Duffeck
0a24d0948f we need to also update the parent layout if there is one
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=735993
2007-11-13 08:34:37 +00:00
Aaron J. Seigo
f242476e72 items were getting added to the same layout more than once. now that the desktop actually knows what its layout is, this screws things up pretty badly. so fix that.
however, the panel is now screwed and will be until i write a proper layout for it. be warned: i really don't want to hear about the panel until then.

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=735280
2007-11-11 09:22:17 +00:00
Aaron J. Seigo
a61562ad95 don't change our state unless the mouse was release inside of the widget
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=735135
2007-11-10 23:58:17 +00:00
Aaron J. Seigo
b0ddc4362d KRUSH: we actually want to set the parent's layout in the Layout ctor, not the BoxLayout. handing out books on OOD seems like a good idea at this point.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=735120
2007-11-10 23:16:32 +00:00
Aaron J. Seigo
4bff9b6912 KRUSH: free layout needs a proper sizeHint
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=735119
2007-11-10 23:13:42 +00:00
Alexis Ménard
6553519076 fix comment
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=734976
2007-11-10 16:06:22 +00:00
Alexis Ménard
1294c4e8a4 Add method to set where we want to put the icon.Usefull for applet
Lock/Logout

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=734943
2007-11-10 15:16:33 +00:00
Alexis Ménard
ae2d05c3c3 add updadeGeometry for methods that need to update the geometry of the
widget

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=734745
2007-11-09 19:28:28 +00:00
Jon de Andres Frias
65dadf4f3f Add 'or later' to the license for the progressbar widget in plasmalibs.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=734236
2007-11-08 09:52:18 +00:00
Aaron J. Seigo
b9b99b4fd2 updated -> dataUpdated to make it really clear what's going on. there are too many update* methods, esp in applets where there is update() and updated()... a painful change, but it will only get worse if it happens any later.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=733314
2007-11-06 07:20:08 +00:00
Leo Franchi
d83f52e2db add support for fixed-size columns. default behavious remains to average item widths.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=733293
2007-11-06 02:46:01 +00:00
Javier Goday
4ed028322c Change in the progressbar widget, only paint the exposed area
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=732765
2007-11-04 18:20:56 +00:00
Aaron J. Seigo
bba7a3d39c invalidate the managing layout on geometry changes, which is what i expected it to do in the first place. calling setGeometry and then updateGeometry is just damaged
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=732530
2007-11-04 05:36:39 +00:00
Aaron J. Seigo
0e7580b89a make this ctor like the rest of the widgets
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=732529
2007-11-04 05:36:10 +00:00
Aaron J. Seigo
ccd0753a96 * fix heightForWidth
* provide a maximum width setting

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=732528
2007-11-04 05:34:10 +00:00
Aaron J. Seigo
ffcf6bc16b let's not hold on to our own parent pointer; just too easy to have it fall out of date.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=731160
2007-10-30 21:00:01 +00:00
Aaron J. Seigo
fab534cf22 only click on left click
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=731159
2007-10-30 20:59:12 +00:00
Aaron J. Seigo
c10ddbe353 the item is already children of us at this point, just make sure to not double add it.
i tried to find a way to reliably react to child add events instead of having to call our own method for this, but due to construction order and how itemChanged events are handled, i couldn't find such a thing. =/

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=731137
2007-10-30 20:25:12 +00:00