Re: Eog port



Hi Claudio and Felix!

> > > Port it to an easier language of course!
>
> Indeed, uh oh :)

Yes of course you are right this is not what should usually be done just
to implement a new feature. I hoped this was obvious from my writing
but I guess I should have added <ironic> tags :-)

> Indeed, I am not a fan of Vala at all, but that's not very relevant to
> the discussion. What I don't think is a good idea at all, is to start
> rewriting software without first discussing it with the people behind
> it, because even when the intention is probably good, the direction
> might not be the best.

Yes of course not discussing the way to go forward can lead to problems.
But I don't think it differs a lot. Imagine my first email would propose
to do a port. Would you encourage me doing it?
So as you pointed out the biggest problem for me would be if someone else
started this at the same time. But except form my time being wasted nothing 
would have been lost.

> > And currently I'm actually already having problems building your branch,
> > probably because my Vala/Glib/Gtk toolchain is newer.

Hmm I am sorry about this, I only tested it on Ubuntu right now. This
will be sorted out later on. But if you send me the output I might be able
to provide a fix right now.

> > Okay, back to Vala. Although I wrote above that I am not into Vala yet,
> > I had the idea that several classes of eog could in fact be converted to
> > Vala (there's a few utility classes and some smaller GUI classes) to
> > make them a bit easier to work with. Even if we won't move to Vala
> > completely we might be able to take some of your work.

This sounds great, even though I don't think it makes sense to only port a few classes.
The reason is that you can't optimize the vala code much if the rest of the code is still in C.
By optimizing I mean to e.g. use simpler classes which are provided by the libGee and similar.

> This is my take on this. Right now, or at any point in time, the last
> thing eog needs is to be rewritten to another language because it
> seems to be simpler. I've seen such energetic efforts before in the
> past and usually they are motivated by inexperience.

No they are motivated out of curiosity. In my case I also wanted to learn vala and see
how far one can get with it. My day job is to program in C++ for the last 6 years.
So maybe it's just the pain I feal every day and I wanted to do something more enjoyable :-)

> This can only lead to frustration once you realize it's not that simple.

In this case the realization was fortunately the other way round. It is actually quite
simple. It only is time consuming...

> But rewriting anything before thinking exactly what's that the GNOME
> image viewer should be, would probably be a waste of effort.

I don't want to add insult to injury but Gnome is right now in a massive rewrite with Gnome3
itself so I think it is the perfect time to also rewrite one of the last stable programs ;-)

> > How do you debug Vala-generated classe? I guess you'll debug the generated C code,
> > which is not that readable.

Yes you debug the generated code. But did you look at the generated code?
In my opinion it is still very readable. The bigger problem is that we lack a decent debugger. 
GDB on the command line is a real pain and nemiver is not very far. I still have to try to debug with eclipse 
and see if that works. But this is not relevant since it is the same problem with the original 
C code as it is with the vala code.

> > libraries (libexif, exempi,...)?  Does every library need to be made
> > Vala-compatible? If yes, this wouldn't be so great. 

No you don't need any library changes. You only need to write a vapi file which describes the C interface. 
And you only need to map the functions that you are using. So it should not be a lot of work 
for the libraries which are missing a vapi file.

So the big question is now how to go forward with this? Should this be continued?

What I am currently doing is to apply all changes between eog-2.32 and eog-3.2.
After that I'll start the bugfixing once again.

Hope to hear more of your opinions!

Sincerely Fabian







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]