Mostrando entradas con la etiqueta focus. Mostrar todas las entradas
Mostrando entradas con la etiqueta focus. Mostrar todas las entradas

lunes, 2 de agosto de 2010

Not that hard after all

In my last post I said that I was having a lot of problems with QTextBrowser implementation because of images size and poor HTML support in general. Well, I was wrong!
After sending a few mails to Roberto Alsina (Lateral Opinion) I managed to display images with custom width and height, without needing to subclass more functions nor using QWebView. Thanks fo the help!

Once done that, I thought it would be cool to fix google-maps-streetview plugin, so I did it, and that's how it looks like:


But that wasn't enough. I was having a lot of free time, so I did a full commits party! Right away from commit 57 to commit 85! Almost 30 commits in one day!
Starting with 57. There was an error in all plugins that support *-more command. They were showing wrong results/current page number/result number.
Next important commit was the range 64-66 in which I implemented Jake-PyQT4 config dialog. I also added another skin. They both look this way:


Some small bug fixes, related with how I was managing prompt and cursor text, configuration parsing/saving, qss coding style, plugins typos, etc.

Commit 81 is interesting because of the focus-on-first-run bug described in my last post.

I should thanks to andresmcid for being such a good beta-tester and reporting bugs instantly via MSN. Thanks!

Also, thanks to nanotube (creator of pyHook) for promising making a release compatible with Python 2.7. Thanks!

Also, thanks to mgrant (creator of python-xlib) for promising making a release fixing some bugs and some annoying output messages. Thanks!

What now?
I'll be probably working on mp3 plugins. But first I'll level up a little bit my skills using Beautiful Soup. Once I think I'm done, I'll start making plugins for goear and filestube. Once I'm done with those, I'll add more.

I don't know when I'll post, but don't expect it too late. (or subscribe via RSS)

Bye!

sábado, 24 de julio de 2010

I made big progress (thanks to mgrant)

As I said in my last post, I was having problems with how Linux manages the focus. Well, thanks to mgrant and python-xlib I finally fixed that problem. Well, there's still some really little bug, but I'll try to fix it next weekend.
The little bug: Run Jake-PyQT4 but don't click on it's window. Now it doesn't have the focus. Hide it and show it. It won't get the focus, but it should get it.
Now quit Jake-PyQT4. Run it again, and this time click on it's window. Hide it and show it. It has the focus! Hide and show it as many times as you want. It will get the focus.
So, the bug is that it won't get the focus if the main app never had the focus. Kind of weird...

Next problem I talked about in my last post was Mac and Xlib for it. After a short conversation in #macports somebody told me that the only way of doing it is using cocoa (wtf?). I really would like to use something else, if not python-pure, at least not cocoa. If I'm not able to do that, sorry Mac users, but I'll have to drop hook system for Mac until I know how to do it.

Last problem was Symbian. Well, I'mm really too far from releasing for Symbian, so I won't even talk for it right now.

So, what have I done last week or so? I did the keyboard hook system! It's on it's own class/file (you can have a look at SVN log for commit 30 here). Also, I did another plugin. !google-maps-distance Realle easy to use. It will return the distance (in km) from point A to point B. I'll do two more plugins using gmaps API. The first one is !google-maps-streetview and the second one is !google-maps-route.

What's next?
After finishing those plugins, I'll work a little bit on the skining manager, I'll fix the look of the config dialog (right now really fscked), I'll right the special config dialog for the main app, and then make the app use those settings.

What about after those changes? 
Most probably I'll do some plugins. I really want to make the !mp3 plugin.
Also, I'm looking at whoosh and I'm starting to think about making a file indexer and searcher plugin. It won't be like strigi and it won't have any fancy things. It will just search for files given a string. Anyways, if you wish to see something more advanced, make a patch, send it to me and I could merge it if it doesn't break anything nor it kills my dog. :)

Next post will appear shortly after finishing !google-maps plugins and it will have some screenshots. Until then, have a good time.
Bye!

domingo, 18 de julio de 2010

[Devs] Blocking problems

One major problem that I'm having is the way that Linux manages the focus. On Windows, the top window has the focus after hiding and showing it, but on Linux things are different.
A top window can exist, but this doesn't mean that it will have the focus.
Also, windows with AlwaysOnTop flag won't have the focus (after hiding and showing the window)
There is also another problem. Most desktop environments have a thing called focus-steal-prevention-system. Yes! People get annoyed when they are typing something and a window pops up and steals the focus. I hate that too. But the nature of my app is different. The idea is to have a global key that will show/hide the app. Once the app is shown, it should steal the focus (really, this sounds annoying, but it isn't at all. In fact, it's usefull. Just try yakuake.)

So, what am I going to do to fix (or work-arround) this problem? I'm talking with mgrant, python-xlib maintainer, and he told me that he's going to merge some fixes into current 0.15rc1 branch, and that he'll work on my problem. Once it gets fixed, I could use his code to make my app steal the focus.
Meanwhile, I'll keep working on plugins.

Another big problem is Mac. Recently VirtualBox added native support for Mac, and I already have a basic install, but I'm lazy I haven't tested Jake-PyQT4 at all on Mac. Also, I don't know what could I use to hook the keyboard (that will let me implement the global key show/hide option). This has low priority for now. I'll try to release first for Linux and Windows. Then for Mac, and finally for Symbian.

Yes, Symbian. That's my last problem. Jake-PyQT4 is written in python and qt4, and both things run perfectly on Symbian devices. Also I don't do any fancy things (well, except the keyboard hook thingy), so it should work somehow on that platform. Or not... I guess that it will work fine on my phone (Nokia N97) because it has a keyboard, but how will users with only touch-screen-keyboard-devices type? If you have any ideas, feel free to share them here.
I'll post again once mgrant has added my feature-request.
Bye!