Symbiatch - maailma on rikki

Me and Qt Quick / QML

19.03.2011 14.20 - mobiili ohjelmointi 

Oh, just wanted to let you know something: I kinda like Qt Quick / QML. It's quite nifty for UIs (naturally since it's copying WPF's XAML ;). It didn't take that long to get into the basic notation, get lists running, some animations etc. Pretty good.

I still have a problem with Qt Creator (in addition to the one I already wrote about). I'm not used to it. It doesn't function like I'm used to. See what I did there? I'm not blaming the IDE, it doesn't have to be exactly like Visual Studio. But it would help ;)

What I don't like is that there are no tabs in the editor. There is a listbox that shows the opened files. There's also a subwindow that shows them. Not the way I like it.

Also I don't like the find functionality. Ctrl-F shows it, it finds stuff, but when I press Esc, it still stays on the screen. And the found words are highlighted. I don't want that. I have to close it every time I use it :(

Also: a kingdom for automatic generation of property methods (AGGGGH!) and why can't I use QList with ListView? All I get is errors about not finding the properties if I don't use QList. And I want to use real types!

I would be happiest with Visual Studio. I had the add-in version 1.1.7. It shows up in VS 2008 and 2010 that I have installed. It kinda works in 2008 but not in 2010. It loads the .pro file and makes a project out of it in 2008, but in 2010 it can't. The project file version is off. Grh. Also in 2008 QML is nowhere to be found. And it doesn't seem to support anything else than desktop. Grhfmggh.

Oh, 1.1.8 is available. Let's install that. Or rather, uninstall the previous one, then install this one. They're still using the crappy Nullsoft installer and not MSI packages. Oh you poor devil children :P

Ok, 1.1.8 won't work either. Why does it say it supports 2010 if it clearly doesn't? Or does it allow creating new projects, just not converting .pros? Gah. 2008 time again...

In 2008 it just gave an error. The system cannot find the file specified. Care to elaborate on which file? No. I don't want to. Naturally. To the command line...

Visual Studio 2010 command line. Ran the command (which the add-in in 2008 kindly did show me), got warnings about Unknown version (160) of MSVC detected for .vcproj. Unknown? You said this add-in was for 2010?

Visual Studio 2008 command line. No errors, warnings about deprecated unescaped backslashes (it's always nice when Nokia ships things that generate warnings). But I got the .vcproj file. Still no QML files in the project, so clearly it doesn't support it. Build and all I get is ERROR PRJ0019: A tool returned an error code from "RCC Project.qrc". Care to elaborate on what error code and which tool? No. I don't want to.

What this means is that by "upgrading" to VS add-in 1.1.8 I lost the ability to even import .pro files. It worked in 1.1.7 a few minutes ago. Not anymore. Oh yeah, I've got the source, I could fix it. But it's not my place to fix it.

So, it's back to Qt Creator. Clearly the Visual Studio add-in is there just to allow people to do something, but not to allow people to actually develop stuff with it. At least if you want to use QML or target mobile devices. That's nice, Nokia. Very nice. Goes so well together with your decision previously to can Carbide.vs, which was the only usable IDE for Symbian development in my book. Carbide.c++ never got to the stage where it was really usable, mainly because of Eclipse.

Disclaimer: yes, I do know that Trolltech did the VS add-ins and it's not Nokia's fault entirely. But hey, they could've at least told the Qt developers that it would be nice if people could actually use QML in Visual Studio (without manual work) and target mobile devices. Even if it means manually making SIS files etc, but just let me test stuff in the simulator...


Qt Creator is Broken, Horribly

19.03.2011 09.51 - mobiili ohjelmointi 

Better to write a separate story about this problem I ran into. It's a big one, really. It might not affect that many people, but it did me. And it's a possibility for a disaster.

As many people know, the Symbian SDK is still in the dark ages. It can't handle spaces in path names. Stupid. And since I'm not an idiot, I don't want to have all my projects in some C:\mystuff. I want to have them where they belong and that is under my profile directory. Which, of course, has spaces in the path.

Tried to compile a Qt app. Didn't work, the spaces. Ok. Copied the project to c:\nokiaisstupid\project\ (not really, but I'm pissed off right now). Compiled, it works. Nice.

Opened a QML file from the Qt Creator. Edited it. Ran in the simulator. Nothing changed. What the heck? Changed something else. Nothing. Strange.

Changed the original file. Changes were visible. Umm, what? Qt Creator opens files from the new location, but builds them from the old! That's nice. And no, clean all doesn't fix it.

Let's remove the original file altogether. Ran just fine. Edited the new file. Still uses the old file. Which doesn't even exist anymore! So it caches stuff somewhere like an idiot?

Clean all. Rebuild all. Still using the old version. Which still doesn't exist.

Search all files in the project directory for the old path. Not found. Search all files in the project directory for main.qml. All point to the new path.

Close the simulator. Close Qt Creator. Still the old version!

So, where the hell is this old version cached? Why does Qt Creator still use it, even though the path is not in the project files, the file doesn't exist etc?

Oh well, let's build a deployment SIS for the device. Maybe it'll notice that something's missing then. Nope! 329 warnings from the Qt SDK itself, none from my code. No errors. SIS created.

Install SIS on device. Oh, right. I can't install the smart installer version, since it doesn't seem to work on E7. Let's send the stupid installer version then. Wow! It uses the new version. As it should.

So, I'm stuck in a situation where Qt Creator doesn't realize that it should use the new file. It keeps its old version somewhere deep inside the simulator and doesn't give up on it.

How about it, Nokia? A quick fix for this in order? Or should I just never create projects in one place and then move them? And recreate the whole project that's currently not working?

The root cause for all this is the stupidity that is simulator work: there is a separate build folder for simulator stuff. Which has a separate makefile. And the build directory is per user. And the path stayed the same. And the makefile has a relative path (as it should). So it just kept on copying the wrong files.

So the fix as I see it: don't use any stupid separate folder for the simulator! Everything I do on a project X should be either inside the project X's folder or somewhere in simulator's/Qt Creator's folder structure. No folders should be created anywhere else. It's just stupid. Oh, right. You can't do that. Since Qmake does not support build directories below the source directory. Cool. But it still builds this one quite nicely without problems when I put it under the source folder. Maybe I'm just lucky.

Or at least use relative paths or give an error message. Yes, there is a warning, but it doesn't say why or what things will be caused by not fixing paths by hand.

So there. I'm sure this will go under "a minor thing that nobody notices since they'll never move files around."

Recap: when Qt Creator creates makefiles for building, please use absolute paths. Also, please use a folder under ProgramData or some other reasonable place. Don't clutter my project folder with Project-build-desktop, Project-build-Symbian, Project-build-maemo etc. They're not my projects. They're just build results. Which are NOT laid out like this in any other IDE that I know of.

Please? Pretty please?


Qt 4.7.2, E7 and Stuff

18.03.2011 23.52 - mobiili ohjelmointi 

Now it's naturally time to try to get my Qt Quick application into the E7 for testing. Updated Qt to 4.7.2 (it's nice that it's only some gigabytes when updating...). Qt Creator up and added device configuration. Build, get a warning about spaces in paths and build bar goes red. Nothing happens. For some time. Change view to Compile Output and there's the typical error about missing path, path being cut at space. Great.

So there are two problems here, still: Symbian toolchains don't handle spaces in paths and Qt Creator can't even show errors in the Build Issues view when building for Symbian.

Hey, it's 2011. When will you guys understand that? It's NOT ok to install your stuff into the root folder. Not even if you can't make stuff work with spaces. Because the correct thing to do is fix it so that it does.

So now I have to save my Qt projects somewhere else than all other projects I do, just because Nokia can't get SDKs done right? That's sooo cool.

Oh well. Let's see if I can at least get the device connected to Qt Creator and get stuff in it. USB connected, drivers installing... And no, I will NOT install Ovi Suite to this machine!

CODA installed on device. Reboot. USB cable in, device says that debug services are available. Qt Creator won't show the device in project settings. I didn't expect anything else...

Setting Up Development Environment for Symbian has been read and done. But noo, naturally it won't work. So what's next? Maybe it won't work with CODA, you have to have App Trk? Though the documentation doesn't say so. Let's try that...

Nope. Not available in Qt Creator still...

Well, let's just make a SIS out of it and send it to the device without Qt Creator. But, how? Build, done. No SIS file. Deploy? No, that would require a connection to the device. Which I don't have. So...? I'm a total newbie with Qt Creator and it clearly isn't as simple as it could be. It seems that I have to create a new build step that runs make sis. Manual work is always great.

But that requires manual installation of Qt on the device. Not nice. So I have to use make installer_sis. Now I get a package that doesn't complain. Testing on device...

Installing... This'n'that... Error: device not supported. Oh really? Why not? E7 isn't supported? That's not going to help. Let's try installing the sis package from the SDK manually. As I said, I do like manual work when developing. It'd be much better for the end users, too, if they had to install Qt manually, don't you say?

Installing... Installation complete! So, yes, E7 is supported. Just not by the smart installer. Ok, this whole thing is beta (even by name, I think it will be beta quality for a long time still), maybe they'll fix it soon.

Try installing the smart version again. No go, not supported. Install without the "smart installer" and it went through. Not so smart after all.

But woohoo, it runs! So, all I have to do now is send the SIS file manually every time I build, since the connection from Qt Creator to the device won't work. And I can't use the "smart installer" since it won't work with an actual device.

So, anyone more familiar with Qt Creator and development who can tell me what I'm doing wrong? It must be me doing things wrong, it can't really be that these things don't work, can it?

Also as a side rant: why the heck hasn't Nokia implemented a better support for Symbian in Qt Creator? "Oh, you can use the testing UIDs when developing and when you want to send the app to Symbian Signed, you must remember to change the UID by hand to another value." Umm, hello? Isn't this supposed to be done by the IDE, not by the developer? Ah, sorry, forgot: manual work is fun. And not error prone.

And it's nice that compiling Qt application for Symbian causes hundreds of warnings. No, not a single one from my code. They're all from the Qt code! Developer 101 time: warnings are bad. You shouldn't get any when compiling. Even if they're "only" warnings. Clearly Nokia doesn't know this.

What the heck?!? When I copied the project to another location (because the Symbian SDK can't handle spaces), cleaned everything many times, but STILL the Qt Creator loads QML files from the wrong place! That is, when I double-click a file to open it in editor, it loads it from newpath\test.qml. When I build the app (for the simulator, at least), it loads it from oldpath\test.qml. Which obviously doesn't work. Separate path handling for project viewing and building? Hello? Idiots anyone? Sheesh!


Me and Nokia E7

16.03.2011 19.13 - IT-ala mobiili 

Ah, the day you've all been waiting for is here: I just got the Developer Gift E7 from Nokia! So now I can complain about all the nice things like I always do and Nokia can keep on not giving a damn. Especially since they're throwing Symbian away. Boohoo. But to the point...

(I'll probably update this as I go along, I've only poked around for a few minutes. And yes, I know that others have written about the device already. I haven't read them and I don't care: this is, after all, my blog and my experiences. I've used iPhone 4 for some months, before that iPhone 3G for two years, so my habits and experiences are mainly from there)

Ah, the start screen. Nice that I'm appreciated for choosing Nokia. Didn't really choose, but anywho :) Language, English please. I don't like Finnish in these things (Finnish people know what I'm talking about when I say akt.valm.til.sov.). Then waiting for ages for it to allow me to choose country. Loading something or other. Blah. Time/date, yeah.

Home screen and all the cool widgets. Not bad. Better looking than I thought. But let's try to get updates. Oh, can't since it won't ask me for wifi connection (no SIM inserted, offline mode). Oh well, I'll do it myself. No updates still. Maybe the 14.x is not available for Finnish devices?

Add email account. Warning about maybe sending info to Nokia. Hope you won't, I won't like it and you don't need my account info. Exchange info input, press next. The same screen stays on, no warning, no error. Umm, what? Let's try next again. Oh, now it asks for email server. And it's done. And finally Nokia understood that not all use domain field. Previous MfE required something in the domain field when using the wizard.

But crap. The email application is quite the same. Ugly, font is horrid (the same font as everywhere else. And it is horrid.) Oh well, maybe it works. Not going to test it yet.

Calendar, then. Nice, it's the same as Android: it only syncs the default calendar! What the crap? Hello, Nokia, this was supposed to be an E device. For Enterprises. And even if I'm not an Enterprise, I do use another calendar for school. Actually, I use two calendars for school. In addition to the default one for other things. So I can't use this for my daily stuff. Nice.

Also, I'm used to the nice and simple calendar view in my iPhone: the list. Ahh, Symbian used to be all about lists. Why isn't there a nice list view for the calendar, then? A list that shows all the items in a loooong list. But no. I certainly only need a list that shows one day at a time. It's so convenient to check e.g. what the next week will be like at school. Oh, I forgot. I couldn't do that anyway since it won't support more than one calendar from Exchange.

The nice Social application wants me to have an Ovi account. Doesn't say why, doesn't say if they'll rip off my account info or anything. I just must have one. What about a little clarification here, Nokia? Also, after I set up the ovi account info, there are no social networks to choose from. Nice. Others have had this problem too. They did appear later when I had inserted my SIM and rebooted the device thrice.

The Social application looks quite bad too. The font is one thing, it's too big and ugly (hey, I can only see ONE or maybe TWO updates per screen, that's nice!). The layout for the items is a bit off, too, many times. In landscape mode a third of the screen is used for title bar and buttons. Why? I do have quite big fingers but I certainly don't need that big buttons.

The Social widget, then. No, not going to use it. Shows parts of latest messages. Changes after a while. Shows "Update status" in between and whatnot. I don't need that. I only need an app that starts quickly and shows me the action. And there's only a status update box but where will it update it? To all networks added? I probably don't want that and I'm not going to test it. So a sub par thing this one too.

Wifi connection is very shaky when in offline mode. As it's always been. Nokia doesn't clearly understand that some people don't use the phone as a phone always. So I'll have to insert a SIM to get things working better. I seem to be getting a working network connection every other time, if I'm lucky. And still the phone shows that I'm continuously connected to the wifi. Strange...

Open SIM slot. "Phone will restart." Ok, fine, you shouldn't have to at this point since there isn't any SIM inserted so nothing changed (iPhone on the other hand just removes phone connection and restores it if you insert a SIM later). Insert SIM, "The phone will restart." Fine.

Phone starts and starts telling me, again, that it's nice I chose Nokia. In Finnish. Didn't I clearly tell it that I wanted English as my language previously? Yes, I did. But it chose Finnish since I inserted a Finnish SIM. What part of "no, no automatic language but English" didn't you understand? Okay, every part of it. Let's reboot the phone for the third time. (And after this I got Social to add networks)

Software update found Search update. Install. Takes a while but clearly does something. I think. Ok. Also some Microsoft communicator app, I don't need it so I won't install. But wait, there's one bug here... Info button is hidden if I select the second update. Deselect it and it's activated. And it shows the first app's details. What about the second? Can't get it to show that any way I click. Clearly a problem with this "click once/twice" shit that Nokia had with Symbian UI. You can get the details of the second one with long touch, though. But still a bug.

Ovi Store. Update needed. Umm, so, Software Update won't update Ovi Store for some reason? Ovi Store will update itself only? That's nice :P

Update installed, starting. Still the ugly (web based?) Ovi Store. That doesn't remember account even though I touched on "remember me." And the constant Unable to contact stores continue. And it's not my network since I'm using the same wifi network without problems on this laptop. Installation works when I happen not to get errors. But I don't want to be taken to my account page after I've selected an app to be installed (still it's better than iPhone's "I'll just take you away from the App Store completely so you can watch the app install)

The screen on the device is lot worse than I'd think. I do have the plastic cover on that is on by default (and I know it's supposed to be taken off, it's just a protection while packaged). The viewing angles are small, the white background changed to red-pinkish when tilting the device. I'm used to using my iPhone from whatever angle, so this is not nice.

Home screen widgets (the default ones at least) are mostly useless to me. CNN? BBC? E!? Reuters? Don't care. How do I remove them from the list? No option in the list itself. Blah!

Music player. Default four songs. That are updated when starting. This is what I don't like about Nokia. True, iPhone gets its database from iTunes sync and I can save songs to this phone from other sources, too. Anywho. I hope the search is faster than in the previous phones. But once again a stupid UI thing: a list of songs (I like this), I select one and I'm shown a coverflow-like menu of... the four songs?!? And I have to select again the one I already selected. What's the point? Nokia UX people to the rescue? (And they still try to get me to use their UX services when clearly they either a) don't use them themselves or b) they're crap).

Ah, almost forgot the browser! Let's start it up... Snappier than previously. Still doesn't seem that great. Oh, right. Multitouch. Zoom works quite nicely. The wifi problems still continue. Maybe it just doesn't like my 802.11n network (some other devices don't either, crappy D-Link station). Anywho. The loading bar is hidden, so I can't see if it's loading or not. And scrolling while loading is not working at least on bigger pages. Oh, sorry. Scrolling while loaded on larger pages is slow and jagged. Better than before, still. And there's still the browser update coming, someday, right?

Camera, then. First I thought it was broken, then I realized it had the plastic protector still on. Silly me :) But wait, no autofocus? Right, this is an E device. Maybe it'll suffice. At least the camera app shows how many pics/how much video I can record. Unlike the iPhone that caused me to miss a couple of things since the video was just stopped with the notification "not enough space".

Now if I only knew what to test next. mIRGGI probably needs a little test run and some other things too. But I'm surely not going to switch from my iPhone to this soon. If the email and calendar apps were done right, I might even think about it. But now it's impossible.

Comments (2) | Comment  |  Omat jutut  |  Muiden jutut  |  Kategoriat  |  kirjaudu