Hello. I'm going to be frank and say that I haven't been the best GSoC student for the last 2 weeks. My project fell to the wayside compared to other issues. I shall be talking with my mentor Cristian when he is back from vacation on the 25th of August.
"Pencils down" is 20th August. I will be working on that basis regardless. Perhaps I will be successful. Regardless, I shall finish the project (though I am away from 10 September to 24 September in America where I'm not allowed work).
I will be working hard from now on to make up for my lack of applied effort.
It has been just over a month since my last post. Not very well done Gavin...
Today I finished implementing the nicer GUI for displaying the printer selection choice. The parser is temporarily broken though :P Doesn't want to recognize the XML tags anymore. I've checked the diff of my changes since it last worked and that the XML hasn't changed. No luck. I still think this will be fixed tomorrow or the next day.
Rapidly filling hard drive space (now since mitigated) led me to completely delete the build and install directories for kde4 today. I'm regretting it now because I've to wait about 2 hours for them to recompile from scratch! And I can't compile a single piece of my code...
What should be a very simple issue with QHash (that requires recompiling some debug stuff in, hence :( ) is halting the XML work now.
I'm please that my madness with XmlQueryJob was stopped. That class was horrible. Simple stuff now. I think LOC was reduced about a third just with that removal!
My tooth chipped today. And my brother just has shaky hands, I'm not that blurry. Edit: photo is gone!
Note: This post is a slightly blogified version of a comment I left to my mentor's comment to my last post. Also note that that sentence is awful. ;)
Yes, I shall be using QtXml module most likely with the SAX2 style variant being the most likely. (I've looked at QXmlStreamReader as it can parse an incomplete bytearray so we don't need the full XML before parsing.)
2 step process: When querying openprinting.org, there are 3 types of information we can retrieve (using the type argument/option):
manufacturer (I likely won't use this)
So, in order to find and download a specific driver for a specific printer, there necessitates 2 queries.
The first query gets information from machine (and perhaps the user) about the printer type. This will also give lots of information about drivers available for the printer (there could even be a list of many recent, functional drivers that could all "work").
The second query will use this driver list (so we need the first query's XML parsed before we can make the second) and make a driver query. Here we can get information about the driver such as the all important download URL.
XML issues all wrapped up. Simple replacement of & with xml syntax of &. I forgot & was used as a kind of escape.
KIO is still not crystal with me yet. Confusion over whether to use KIO::Job or KJob is the main issue. (The confusion is actually a result of every doc telling me to use KIO::Job but KJob being the only thing that actually works!)
XML parsing is next up on the agenda. There are of course niggles and slight inefficiencies with my current setup but they are minor relative to just getting the god damn work done.
Very nice framework though I still seem to be doing some more laborious work than I'd like.
I'm also having an issue with it... not working. I want to have a string with a default value which is: http://openprinting.org/query.cgi?type=printers&format=xml&moreinfo=1&showprinterid=1
So I have something like: <pseudoxml> <group name="openprinting"> <entry name="QueryUrl" type="String"> <label>The query URL we use to download the XML file from openprinting.org. <whatsthis>This is the query URL we use to download an XML containing a list of printers from openprinting.org.</whatsthis> <default>http://openprinting.org/query.cgi?type=printers<!--&format=xml&moreinfo=1&showprinterid=1--></default> </entry> </group> </pseudoxml>
Notice that I had to comment out the ampersands parts. I kept getting errors such as: <error> /home/kde-devel/opt/kde/bin/kconfig_compiler /home/kde-devel/kde4/src/KDE/kdebase/runtime/kdeprint/kopenprintingdotorg/kopenprintingdialog.kcfg /home/kde-devel/kde4/src/KDE/kdebase/runtime/kdeprint/kopenprintingdotorg/KOpenprintingConfig.kcfgc -d /home/kde-devel/kde4/build/KDE/kdebase/runtime/kdeprint/kopenprintingdotorg Unable to load document. Parse error in /home/kde-devel/kde4/src/KDE/kdebase/runtime/kdeprint/kopenprintingdotorg/kopenprintingdialog.kcfg, line 13, col 83: error occurred while parsing reference </error>
Where line 13, col 83 was the first equals after an ampersand. I had a quick look at the xsd file but couldn't find anything - I guess I just have to look up some basic xml escaping or some such. Should be no problem.
Today could perhaps be described as my first day at the office - though not quite. I am quite finished with exams (delight) but I am exhausted (less delight). I got about 9 hours sleep last night which was about twice as much as I'd had in the last 3 days so I'm completely on the mend! Tomorrow will be first day proper.
I also decided not to build today as Monday is "commit gay patches day".
So today has been 2-3 hours of toying with KDevelop and compiling version 6.6 of gdb as stated necessary on techbase. Debian packaging was something I also thought might be useful so, decided to have a bit of a go at that! Some decentdocs available too. Quite easy really but needs some slight modifications for new users and people making packages that are not meant to be uploaded. Might do so myself but I'd say it's also available somewhere else... too many debian sites in my opinion as it is.
So, going to see The Fountain tonight and then tomorrow morning is proper work.
I decided to reinstall Debian Etch and get some LVM shiznit going on so I've been somewhat delayed in getting my build environment up. Also, I have been doing exams... I don't quite know how to describe how much of an understatement that is... except through ellipses apparently... ...
And yes, it IS the first post and NO I don't like how I felt obliged to say it. :P