From kde-devel Sat Oct 29 23:12:18 2005 From: Angus Leeming Date: Sat, 29 Oct 2005 23:12:18 +0000 To: kde-devel Subject: Re: unsermake and qtonly Message-Id: X-MARC-Message: https://marc.info/?l=kde-devel&m=113062756501162 Benjamin Meyer wrote: > On Saturday 29 October 2005 11:42 am, Angus Leeming wrote: >> Hi! >> >> I'm attempting to port KDVI to Windows >> http://sourceforge.net/projects/qdvi >> by stripping out the kdelibs dependencies. > > Do you happen to have a list of what features you had the hardest time > removing/replacing? My real difficulty has been in keeping the four repositories in sync. (Two QDVI and two KViewShell, one for the 3.5 "working" branch and one for the trunk) Fortunately, the KDVI developers, Wilfried and Stefan, have been more than welcoming, and I've been able to contribute some bits back to the kdvi sources as I've gone along with my big boots on, stomping on things. It'd be nice to think that the two repositories will merge a little, using common wrappers for things like kdDebug/qDebug, KMenu/QMenu. That would make it easier to see where the real, substantive changes are. Onto the code: KDialogBase was a bit of a challenge. I think that my result, qdvi_dialogbase.{cpp,h} in the trunk repository is a lot cleaner, but then I would, wouldn't I :) I've managed to replace the (Janus and MainWidget) pointers with just one, but I've still to port KJanus. Fortunately, I need only a tabbed view for QDVI and Qt4 does most of the work anyway. I'd say, as a newcomer looking in, that there's a fair bit of redundancy between the non-gui parts of Qt and KDE. For example KProcess and QProcess do the same thing. I can, of course, see why both have existed historically, but certainly as far as KDVI is concerned, there's no need for KProcess anymore. Similarly, why KTempFile/QTemporaryFile, KURL/QURL/Q3Url... ? The main problem I've had is that of any newcomer: not knowing where to look first :) That's not helped by the fact that the KParts code (which I don't need at all) is not documented very well. I spent the first 6 weeks or so just trying to get familiar with the code. Only in the last month or so have I made real inroads into the port. If we look at the remaining kdelibs includes in QDVI, they can be split into three parts. Part A is the DVI widget itself. That's everything up to the first ====================== line below. Part B is the stuff that I've wrapped up in qdvi_foo clothes and that will need porting eventually. That's everything up to the second ====================== line below. qdvi_messagebox, qdvi_iconloader, qdvi_dialogbase. Lots of work, but none of it very technically challenging. Part C is the supporting main window, toolbars, menubars, statusbar. That's everything below the second ====================== line below. I plan to keep parts A and B, replacing the kdelibs stuff, and to throw away part C, writing my own simple interface. As such, the list below no longer looks toooooooo scary :) qdvi/dviRenderer.h: #include qdvi/kmultipage.h: #include #include qdvi/kprintDialogPage_pageoptions.h: #include qdvi/kviewpart_iface.h: #include #include qdvi/dviRenderer.cpp: #include #include #include qdvi/dviRenderer_export.cpp: #include #include #include qdvi/dviRenderer_prescan.cpp: #include qdvi/infodialog.cpp: #include qdvi/kdvi_multipage.cpp: #include #include #include #include #include qdvi/kmultipage.cpp: #include #include #include #include #include qdvi/optionDialogSpecialWidget.cpp: #include qdvi/presentationwidget.cpp: #include #include qdvi/psgs.cpp: #include qdvi/renderedDocumentPagePrinter.cpp: #include qdvi/special.cpp: #include ============================================================ qdvi/qdvi_messagebox.cpp: #include #include #include #include #include #include #include qdvi/qdvi_dialogbase.cpp: #include #include #include #include qdvi/qdvi_iconloader.cpp: #include #include ============================================================ qdvi/kviewpart.cpp: #include #include #include #include #include #include #include #include #include #include qdvi/kviewshell.cpp: #include #include #include #include #include #include #include #include #include qdvi/main.cpp: #include #include #include #include qdvi/qdvi_mainwindow.h: #include qdvi/qdvi_mainwindow.cpp: #include #include #include #include #include #include >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<