http://code.google.com/p/arora/wiki/KDE4Integration
-Benjamin Meyer
>> What other ideas do other people have?
>>
>> -Benjamin Meyer
>
>
> First thing that comes to my mind (besides previously mentioned) are:
> - toolbar dots/handles, KDE apps have "Lock/Unlock Toolbars" option in
> context menu (to hide/show them), along with stuff like text position,
> orientation and icon size.
> - KDE icons in menus
I have added this to the wiki
> - hide/show menu option (it seems that every KDE app has
> "settings->show/hide menu" option)
We have it to, just in View -> Show/Hide Menu
The others were Oxygen issues which are already on the wiki.
-Benjamin Meyer
Well a Q->K replacement is easy. Anyone can do that (and several
already have.. and stopped there), but that doesn't solve any of the
issues that are listed on the wiki (http://code.google.com/p/arora/wiki/KDE4Integration
). Oxygen still has bugs with QtWebKit and QLineEdit and QTabBar and
with giving KDE icons. Integrating with KDE isn't primarily about
replacing one class with another, that is only one very tiny part of
it. Integrating with KDE is making Arora utilize KDE's resources.
I have stayed away from the Q->K topic, but I figure it is time to
dive into that a bit for the record. For those who have not seen it
checkout the project goals wiki page which was created at the start of
the project: http://code.google.com/p/arora/wiki/Goals. One of the
sections is Non-Goals and contains the following:
"The following consider out of scope for the project
Single Desktop Browser
Arora will not strive to become a KDE browser or only a Windows
browser. Specifically on Linux Arora should fit just as well in Gnome
as it does with KDE. Rather then calling it a Linux browser perhaps it
should be called a FreeDesktop?.org Browser. Specific features to
integrate with KDE, Gnome, OS X, or Windows should be built as
extensions whenever possible."
It sounds more harsh then it is. Arora should strive to integrate
with each desktop environment. Arora *must* be able to build and be
distributed stand alone on Windows and OS X. Arora must be able to
integrate with KDE and Gnome using the same binary. I do not think
that this is to much to ask. Switching QMessageBox to KMessageBox
wont integrate Arora into KDE (I believe they will look the same), but
fixing Oxygen to return the KDE stop/reload icons will.
Switching Q->K in master will require every developer of Arora to have
a new dependancy of kdelibs (and kdebase?). This is no small
dependancy and will force those developers to build KDE. Worst of all
it will be a moving target for at least another year. You can develop
Arora today with just the stable Qt 4.4, 4.5 is nicer, but not required.
Ok, so that is the worst case scenario. A change like this would have
to be done in a branch to determine the issues and benefits. One
possible solution might be to have a kde.h that redefines all of the
useful classes and is only enabled on Linux. Details like how to
build on Windows and OS X, will Gnome integration still work? will it
build on QtEmbedded (we have users there)? How would we package kde*
with Arora for an Arora.app bundle on OS X? We want/need Qt 4.5 the
day it is released, will be be tied to KDE 4.2 and Qt 4.4? And many
other questions that I don't have the answers to.
Arora is somewhat like Amarok, an application that isn't in one of
application in the KDEfoo svn repositories and has its own release
schedule. But honestly I think the Q->K is simply the easiest thing
to do which is why a lot of people bring it up, but it gives the least
bang for the buck . The actual work that needs to be done is what is
on the wiki page. When those are fixed users will be happy, no doubt
about it. I am not saying Arora should not change Q->K, just that it
wont happen until it is shown that it doesn't conflict with the goals
of the project. A branch on github to play around with it that can be
tested on all platforms is a fine way to move forward with the
transition. While that is going on we should look to solve the issues
listed on the wiki page. They will benefit Arora whether we use Q
classes or K classes and make the KDE users more happy with Arora.
-Benjamin Meyer
For exemple for the security device you can do AbstractSecurityDevice,
DefaultSecurityDevice, KWalletSecurityDevice, ... and load the right
one during startup.
For the shortcut, AbstractShortcutManager, DefaultShortcutManager,
KShortcutManager, ...
For the bookmark provider, ...
And do you really need cmake ? There is `kde4-config --path include',
... which is what you need to configure it with qmake.
> As Benjamin already pointed out, making Arora a platform specific
> browser is not an option (because it's not Arora's goal) and IMO it's
> very good, so the idea is to make a browser that integrates with KDE
> desktop very well and sort of inherites (or extends) Arora.
Arora can be integrated to a platform without being platform specific.
Use abstraction.
--
Alexandre Bique
No, you build plugins. They go in $prefix/lib/arora/. At startup you
can load them and use them. So if you don't want KDE, you may not
build the kde plugin. And at startup you just load the plugins you
want. You can detect the current environment and choose the right one
or rely on the user preferences.
> I'd really like to make as small changes to Arora as possible for
> couple of reasons, but on the other hand I'd love to make it an KDE
> app, so it's not an easy task find the right balance and your input is
> helpful.
>
>> And do you really need cmake ? There is `kde4-config --path include',
>> ... which is what you need to configure it with qmake.
>
> Yes. And it's already done. Correct me if I'm wrong, but cmake is
> easier to setup for KDE development than qmake, but IMHO the biggest
> advantage of havening separate build system is that it's easier to
> compile it with different versions of various classes. If there is an
> easy way to do it using only qmake please let me know.
With two build system, you do two times the same thing. If the first
one work, why do another ?
>> > As Benjamin already pointed out, making Arora a platform specific
>> > browser is not an option (because it's not Arora's goal) and IMO it's
>> > very good, so the idea is to make a browser that integrates with KDE
>> > desktop very well and sort of inherites (or extends) Arora.
>>
>> Arora can be integrated to a platform without being platform specific.
>> Use abstraction.
>
> Yes abstraction is good and thats basically what I meant by "extending/
> inheriting Arora", but it's not always easy. I'm not an expert, but
> how do I abstract when I need to change base class?
template <typename A>
class B : public A {};
KApplication is a QApplication right ? So for the static type, use
QApplication * myApp = createApp(); // dynamic type can be B<KApplication>
Here createApp() can load a plugin with the desired [KQ]Application base classe.
> Please remember that for now we're evaluating different possibilities,
> playing with code and looking for possible traps and pitfalls. If
> there is someone who have experience with kdelibs and KDE programming
> it would very helpful if you could give us some clues and suggestions,
> especially that some parts of KDE4 are documented partially or not at
> all yet.
>
> So as for now please consider it as an experiment and any suggestions
> are very welcome :)
PS: Please Benjamin, can you remove the google's footer ?
--
Alexandre Bique
Done
-Benjamin Meyer
You can try:
class AroraApp : public QObject // you don't change the base class
{
private:
QApplication * app_; // dynamic type can be KApplication *
};
But if you want to change every Q* to K*, you may use defines:
// choose the one you want
#define API Q
#define API K
#define AApplication API##Application
#define APushButton API##PushButton
...
It should work. And i think that's what you did. But you will get
karora, not arora ^^.
I don't know what is the best think to do... :'(
--
Alexandre Bique
But how far does it improve arora to be karora ?
Where is your repository, i wanna try your version.
--
Alexandre Bique
I don't know, I think that it's too much pain ;-) Have you got a look
at rekonq ?
--
Alexandre Bique