Re: Porting KWidgets to Qt5
Hi, 2012/7/9 Иван Комиссаров: I answered to them. They disagree with them in that case. For me is biggest priority is to port as much kde as code as possible. getting code upstream into Qt is good, of course, but you can't expect that the Qt people will accept KDE code without modifications. If they have good suggestions how to make the API better and more general, you should take this into account, e.g., Jeremy's idea to just have a 'tabClicked()' signal with a 'mouse button' argument. One could even go further and add a 'keyboard modifiers' argument. Things like this make the API more versatile and future-proof. Some evidence to support that: QAction's triggered() signal yields no info about how the action was triggered [1], which makes it impossible to react to middle-clicks or Control-clicks on, e.g., toolbar buttons, in a special way. Therefore, KAction has another triggered() signal that has information about mouse buttons and keyboard modifiers [2]. This wouldn't be necessary if QAction had been written in a more general way. Best regards, Frank [1] http://doc-snapshot.qt-project.org/5.0/qaction.html#triggered [2] http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKAction.html#a47c884a5a7b9b2284553fd5552a8 ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Re: Porting KWidgets to Qt5
Hi, 2012/7/9 Иван Комиссаров: Hm, it seems that Qt guys are not very happy seeing KDE features in qt. I would like someone from KDE to participate in discussions about changes. For example, they insist that KTabBar functionality is not needed as it can be easily implemented in subclass:) https://codereview.qt-project.org/#change,29650 If someone from KDE is really interested, they can send me gerrit account, so i can add them as a reviwers IMHO, the constructive criticism that your patch set 4 got from Jeremy Katz makes sense. To me, it looks like the problem is not that Qt guys are not very happy seeing KDE features in qt, but that you did not take his arguments into account. Best regards, Frank ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Porting KWidgets to Qt5
Hm, previos message was rejected as spam:) Ok, if KDE devs can live without tis signal, i can live too. However we could just rename it to something less specific than 'newTabrequested but not confusing with doublClicked(). So, before i start other work with tabbar i would like to ask some questions. 1) I can add property autoHideTabBar to hide it when tab count is equal or less than 1. Is it needed? Should it be added to both QTabBar and QTabWidget? 2) I can add property switchTabsOnDrag to allow automatically changing tabs when user drags something over it. Is it needed? ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Re: Porting KWidgets to Qt5
On Monday 09 July 2012 15:46:25 David Faure wrote: PS: calling people stupid won't get you far in terms of respect within the Qt community. Or the KDE community for that matter: http://www.kde.org/code-of-conduct/ Regards. -- Kévin Ottens, http://ervin.ipsquad.net KDAB - proud patron of KDE, http://www.kdab.com signature.asc Description: This is a digitally signed message part. ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Re: Porting KWidgets to Qt5
Ok, that's very interesting, but i asked two questions and still don't see any answer. No offence, Kevin, i just prefer discuss code, not my communication skiils. 09.07.2012, в 18:34, Kevin Ottens написал(а): On Monday 09 July 2012 15:46:25 David Faure wrote: PS: calling people stupid won't get you far in terms of respect within the Qt community. Or the KDE community for that matter: http://www.kde.org/code-of-conduct/ Regards. -- Kévin Ottens, http://ervin.ipsquad.net KDAB - proud patron of KDE, http://www.kdab.com ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Re: Porting KWidgets to Qt5
On Monday 09 July 2012 18:05:07 Иван Комиссаров wrote: Ok, if KDE devs can live without tis signal, i can live too. However we could just rename it to something less specific than 'newTabrequested but not confusing with doublClicked(). And we can also add an if() in the apps when porting them away from KTabBar (and renaming the signal and slots anyway), no big deal. So, before i start other work with tabbar i would like to ask some questions. 1) I can add property autoHideTabBar to hide it when tab count is equal or less than 1. Is it needed? Yes this seems very commonly used. http://lxr.kde.org/ident?i=setTabBarHidden Should it be added to both QTabBar and QTabWidget? I guess so, although if it's deemed too corner-case then having it in QTabBar only is good enough (now that tabBar() is public). 2) I can add property switchTabsOnDrag to allow automatically changing tabs when user drags something over it. Is it needed? Interesting, KTabBar seems to do this by default, without even an option to turn it off? I wonder if this means QTabBar should do the same, or if it should indeed be enabled explicitely. I'm not sure if there's a use case for *not* doing it (especially with a timer, like in KTabBar, so that stuff doesn't jump around all the time). I would try to implement this without a property first, or to ask on the qt development list whether anyone would object. But of course a property is fine with me too. -- David Faure, fa...@kde.org, http://www.davidfaure.fr Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5 ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel
Porting KWidgets to Qt5
Hello. On a qt5 mailing lists we've discussed possibility of adding come kde widgets to Qt5. I made a list of widgets i can try to add myself: 1) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKIntSpinBox.htmlbase; property can be added to QSpinBox. 2) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKFontRequester.htmlcan be added as a separate qtwidget instead of FontButton mentioned eariler (i personally prefer widget). 3) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKColorPatch.htmli prefer QtCreator's QtColorButton here (it has some API, at least) 4) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKDualAction.htmlnice, but i don't like API (duplicated active/inactive methods plus QAction own setText/Icon/etc methods). Need more discussion here 5) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKLineEdit.htmli won't deal with QLineEdit, but it needs following features - clear button, custom menus (Creator's FancyLineEdit functionality) and ability to draw placeholder text even if QLineEdit has focus 6) http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKTabBar.htmli would like to add mouseMiddleClick(int index) signal, mouseDoubleClick(int index), mouseDoubleClick() or newTabRequest() signal (i prefer first name - more flexible) to QTabBar and QTabWidget. Reasoning - people need to subclass QTabBar/set event filter to track double clicking on an empty space. Also i would like to see property that allows to set if QTabBar should switch tabs while user drags mimedata over it (common FileManager/browser functionality). I would like to see prop for autohiding tabbar when there's only 1 tab. Same is for close button - most tabbed apps do not allow to close last tab. Also, i have some widgets that can be useful - QtCreator's QtColorButton (KColorPatch analog), Arora's ModelMenu/ModelToolBar (kde should have some analogs), WindowsMenu (menu with list of top-level windows and actions for minimizing/maximizing.closing of current window). Does anyone have any thoughts about what widgets can be added? Ivan ___ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel