it makes the tabbar eventually vertical and appearing oriented differently towards the content
possible values:
Qt.TopEdge (default)
Qt.LeftEdge
Qt.RightEdge
Qt.BottomEdge
ToolTipDialog is not a Q_GLOBAL_STATIC because QQuickwindows as global static
are deleted too later after some stuff in the qml runtime has already been deleted,
causing a crash on exit
Only link against OpenGL if Qt links against OpenGL. This ensures
that we don't run into issues if Qt links GLES and plasma links
GL because that's found.
REVIEW: 115990
if more than one dialog is shown in a loop, causes requestActivate called to different windows too fast, this causes 100% cpu usage both in the application and in the windowmanager (not kwin specific)
This way we only call the expensive syncToMainItemSize once we have all
the information to accurately position the window.
Using the timer to limit the calls doesn't work entirely (according to
qDebug) especially with the multiple threads to compile things.
Seems to prevent the dialog ever jumping around on load.
REVIEW: 115709
* X11 is optional dependency
* XCB is optional dependency
* Qt::X11Extras is only found if both X11 and XCB are found
* switch to HAVE_X11 instead of X11_FOUND in CMakeLists
* remove/fix custom added definitions
* use #if HAVE_X11 instead of #ifdef HAVE_X11 (that is always true)
REVIEW: 115698
This is useful to be able to disable tooltips when a dialog exists.
We don't use the QQuickItem::enabled property as this propagates onto
children and has side effects.
REVIEW: 115623
The minimumWidth of a plasma button is based on the paintedWidth
of the text item. There is no way to work out the correct width it
should be if we set the text to elide.
(except for the hack of using a hidden fake text item)
We should always fit contents. This won't cause any problems unless a
developer has a broken layout, at which point that should be fixed
REVIEW: 115500
This patch makes two changes:
1) don't rely on window()->screen() it's rubbish.
2) if the dialog is parented to a desktop, we want to position
inside the parent, not outside the parent object
REVIEW: 115448
BUG: 330546
This reads the global animation duration value from plasmarc, and gets
notified of changes: change the file, all animations are updated
automatically.
Put this into your plasmarc to disable animations globally:
[Units]
longDuration=0
As you might guess, other values will work as well.
shortDuration will always be 1/5 of this. (For now.)
This may sound a bit weird, but we can't just switch off everything, as
in some cases, the animation is not just eye-candy, but carries
important semantics of the UI -- examples are BusyIndicator and
ProgressBar. Behaviour for those is restored.
These centralize the duration of animations, currently set to 250 and 50
milliseconds. They're notifiable since we want to be able to switch off
animations at runtime.
CCMAIL:plasma-devel@kde.org
For the WidgetExplorer we want to show the tooltips to the right of the
scrollbar in the view, not to the right of the delegate the tooltip is
for.
This patch checks if the visualParent is in a dock. If so the popup is
positioned outside
I have also introduced a manual test for Dialog Positioning, and
includied some fixes in the original logic.
REVIEW: 115393
QWindow::screen() never ever changes if the window is moved across
virtual screens (normal two screens with X), this seems to be
intentional as it's explicitly mentioned in the docs.
Until that's changed or some more proper way of howto get the current
QScreen for given QWindow is found, we simply iterate over the virtual
screens and pick the one our QWindow says it's at.
This also fixes the OSD having proper shadows in multiscreen environment
This is used nowhere, so better get rid of it before someone gets the
idea.
Leaves us with only one non-scaled icon size. Maybe worth considering to
get rid of this as well, and let Folderview decide?
This is still pretty rough. It seems to work fine for larger icons, but
smaller ones get misaligned. This will need some corrections, such as
locking the smaller sizes to 16, 22, 32, 48, 64, which should take care
of this issue.
With this change, parts of Plasma scale depending on the DPI. This is
noticeable in Kickoff.
It was an int already anyway, so let's be true about this and also
return an int. This reflects pixel-alignment in the API, not just in the
implementation.
QWindow::setFlags is manipulating the same X property as
KWindowSystem::setType. Thus our setType never succeeded as the
setFlags overwrote the window type again. In the same way we
have to call setFlags when reverting to the default Normal type.
REVIEW: 115258
The last bits have moved out of ThemeProxy, units is used for iconSizes,
which means we can finally directly use Plasma::Theme, and don't need a
ThemeProxy class anymore.
This is means two things:
- icon sizes have moved from theme.iconSizes.* to units.iconSizes.*,
will provide porting script and update docs
- we can kill PlasmaCore's ThemeProxy now. Icon sizing and dpi handling
is kept outside of Plasma::Theme for now, as it pulls in too many
deps.
This change does two things:
- it increases the gridUnit to 11 pixel on 102DPI, 18 on 170DPI. This
means on the one hand larger sizing, but aligns gridUnit and
theme.largeSpacing consistently, and thus makes these types work
together better.
- it scales the gridUnit with the DPI. The width of the font's bounding
box doesn't change on the displays I've tried, the height does.
As a result, gridUnit now scales linearly with the DPI setting.
The outputOnly property allows to specify that the dialog should not
accept any input. Thus it's an output only window which supports click
through. This is obviously platform specific and so far it is only
implemented for the X11 platform using the shape extension.
The input shape needs to be set once the window is visible and thus
the functionality is bound to the visible changed signal. The code
ensures that the required shape extension version is present and only
fetches it once.
REVIEW: 115139
The QQmlPropertyMap isn't moved with this commit, this needs a bit more
changing, so we do a separate one for that, once the more trivial stuff
is moved out.
ToolTipArea.containsMouse allows the use to update the tooltip way
before it's shown, or when the contents of the tooltip should change
within an open dialog.
dismiss() and keepalive() allow handing over the tooltip dialog to
another item, in order to allow for a smoother handover when a new item
recycles the tooltipdialog. This avoids flickering when the tooltip
moves from one item to another.
- Derive from MouseEventListener as to let input through
- react to target changes: reparent the MEL accordingly
- kill a bunch of warnings
This "helps" a bit, but still filters out input events since the MEL
only passes events down to children, but the tooltip's target becomes
its parent.
Reparenting the target crashes, and it seems a pretty ugly thing to do,
anyway, since we don't want to mess with the scenegraph structure just
to filter events out for tooltips. Grmblz.
Delete KDeclarativeMouseEvent when emitted
Do not leak KDeclarativeMouseEvent press and hold events when the mouse
moves.
Do not create KDeclarativeMouseEvent when the mouse is hovered. It's
pointless.
The larger headings are a bit softened, to make their stick out less,
the font is meant to take care of this. Result: visually more consistent
colouring, strangely. Human eyes are beautifully complex things.
Since we are checking if the width() is out of bounds we should also use
width() to correct the position.
Other cases might need change as well, but I think we better go in a case
by case bases to fix all possible issues.
- We would only check for the available screen, but not for the location
when applying borders. Fix that.
- Cache dialog geometry when going fullscreen, so we can restore it when
we're not fullscreen anymore.
- Remove temporary var l, we have m_location for that.
This is a needless duplication of the property, and it causes bugs.
Removing it, and porting all users to the flags property from QWindow
magically makes layering and resizability bugs vanish.
One problem is left: the dialog dismisses too easily, it should not
dismiss when being resized, moved or when a child dialog or QMenu opens
from it.
Interestingly, this hack yields the correct behaviour in my system. We
quickly set the always on top hint once we're supposed to hide, so the
window stays on top for the duration of the animation -- without
apparent side effects on the positioning and resizability.
CCMAIL:mgraesslin@kde.org
This property is meant to bring back the functionality provided by
PopupApplet. If the property is set to true the dialog gets hidden
when it loses focus.
REVIEW: 114378
Reason for this change: a QIcon might not contain the disabled pixmaps.
Using the icon effect allows to get also the disabled state for such
icons.
REVIEW: 114334
KLocale is now kde4support and we have QLocale QML bindings. This patch
removes the KLocale bindings from plasma-framework (they are not used
anywhere anyway).
If we miss something from KLocale in QLocale, we should upstream it.
REVIEW: 114150
These methods are in the middle of other together-related methods, for
no reason. Looks like corn flakes in the middle of beer. Sure, you can
do that, but why would you. Actually I should try that.
Some CLDR (locale) data used by Qt have standalone month names
starting with lower-case letters. So if we want to provide consistent
look across locales, we need to capitalize it ourselves
See https://bugreports.qt-project.org/browse/QTBUG-35100
Also rename startDay property to firstDayOfWeek property so it's more
clear what it does. Handling the first day of week is changed a bit too
as QML uses 0 for Sunday while QDate uses 7 for Sunday, so the
getter/setter is accomodated to that fact and converts from 0 to 7 on
setting and vice-versa in the getter.
REVIEW: 114099
Stop using classes from kde4support:
- KComponentData is deprecated, it will be using QCoreApplication::
applicationName() and QCoreApplication::applicationVersion(). Of course,
this means that the existing shells will have to be ported. I have no
problem with doing that port myself, if I'm told where to look into.
- Drop usage of KLocale, ported to QLocale
- Drop usage of KStandardDirs, ported to QStandardPaths
- Drop usage of KIcon, ported to QIcon
Furthermore, there's a module in src/declarativeimports/locale that IIUC
exposes KLocale bindings to QML. A specific plan to port it should happen
as well.
REVIEW: 113920
This allows us to keep minimal API, since the calendar view and import
really belong together. Also makes it a lot easier to provide a separate
Calendar Plasmoid.
Accessors to allow centralized control of spacing in a DPI-friendly way.
Will be used to unify spacing across default widget to make them look
more consistent.
Currently, smallSpacing is font height / 10, large is font height / 2.
Calling DialogShadows::self()->addWindow(...) will create the low level window.
If this is called before the property windowFlags is evaluated the window flag
X11BypassWindowManagerHint has no effect as that one must be present when the
window is created through the low level xcb call.
This was breaking declarative KWin scripts as KWin's windows need to have the
X11BypassWindowManagerHint.
REVIEW: 113700
Removes the find_package(Qt5Transitional) and does the proper
find_package(Qt5) with the list of modules.
Most of the porting is about using the Qt5:: targets.
REVIEW: 113345
This is in line with the frameworks naming policy, camelcasing. Up until
now, libplasma was the only library being KF5::plasma, that is now
KF5::Plasma.
Recursive window thumbnails would look awesome on the screen, but reality
is that X/OpenGL or $DEITY doesn't like it at all and decided to just
freeze the view.
So let's delay all the redirecting till the WindowThumbnail has been
added to its QQuickWindow and if the window id is the one of the own
window we just render the icon instead.
New qquick item in PlasmaCore to render a live updating window
thumbnail. The implementation uses XCB to redirect the specified
window using the composite extension. This means a running compositor
is not required. Through the damage extension the item tracks changes
to the window and triggers updates of the texture. Furthermore the
item tracks geometry changes of the window to recreate the window
pixmap.
If the pixmap of the window is valid, a texture is generated from it
using the glx texture from pixmap extension. For this a new optional
dependency for glx is added. On platform where glx is not available
(e.g. Windows, Linux with OpenGL ES) this will not get compiled and
the window's icon is used instead as a fallback.
REVIEW: 112142
Uses the new components syntax of FindXCB. So far plasma frameworks
only need the XCB component and that one is optional just like XLib.
The find xcb is moved to the toplevel CMakeLists.txt together with
the find x11 and HAVE_X11 gets set only if both X11 and XCB are found.
REVIEW: 112499