Feature #123

Port to GTK+ 3?

Added by X. W. about 1 year ago. Updated 4 months ago.

Status:In ProgressStart date:08/11/2013
Priority:NormalDue date:
Assignee:Kentaro HAYASHI% Done:

0%

Category:-Spent time:-
Target version:-

Description

Dear Mr. Yamamoto,

the initial version of GTK+ 3 already has been released more than two years ago. But Sylpheed still is utilizing the old GTK+ 2.

Why is that?

And will Sylpheed be ported to GTK+ 3 anytime soon?

bug123-20140601.tar.gz - patch to use newer version of API instead of deprecated one (20.5 KB) Kentaro HAYASHI, 06/01/2014 10:37 PM

bug123-20140611.tar.gz (19.6 KB) Kentaro HAYASHI, 06/11/2014 12:37 AM

History

#1 Updated by X. W. about 1 year ago

PS:

Just wondering:

Or do you plan to port Sylpheed to something entirely different, like Qt for example?

#2 Updated by Hiroyuki Yamamoto about 1 year ago

  • Priority changed from Immediate to Normal

Porting to GTK+3 is roughly planned, but no progress yet.

I had also thought of porting to other platforms like Qt,
but it will be almost same as full rewriting.

#3 Updated by X. W. 10 months ago

Dear Mr. Yamamoto,

i just wanted to let you know that i just had a look at Audacious 3.4.2 Win32:

http://audacious-media-player.org/

It uses GTK+ 3 on Windows and it seems to work just fine :). So, maybe you want to have a look at it yourself as well.

In feature request #124 you said you can not upgrade GTK+ 2 on Windows because of font rendering problems.

So, could you please start porting Sylpheed to the latest GTK+ 3 and release a GTK+ 3 Sylpheed Win32 ;)?

It would be much appreciated.

Regards

#4 Updated by X. W. 10 months ago

PS:

GTK+ 3 Win32 is also available on gtk.org now, see:

http://www.gtk.org/download/win32.php
http://www.gtk.org/download/win32_tutorial.php

:)

So, please port Sylpheed to GTK+ 3 ;).

Regards

#5 Updated by Kentaro HAYASHI 8 months ago

  • Assignee set to Kentaro HAYASHI

#6 Updated by Kentaro HAYASHI 5 months ago

As a first step, we need to use newer version of API instead of deprecated stuff.
Here is the list of patch a bit supports newer one.

I've attached a patch set bug123-20140601.tar.gz. This archive contains following patches.

Mr Yamamoto, please review and merge into svn HEAD? I've created this patch set for r3404.

% ls -1 bug123-20140601
0001-use-g_path_get_basename-instead-of-g_basename-123.patch
0002-don-t-use-g_strdown-123.patch
0003-use-g_mapped_file_unref-instead-of-g_mapped_file_fre.patch
0004-use-g_io_channel_read_chars-instead-of-g_io_channel_.patch
0005-use-g_thread_new-instead-of-g_thread_create-123.patch
0006-use-GtkTooltip-instead-of-GtkTooltips-123.patch
0007-use-gtk_widget_set_tooltip_text-instead-of-gtk_toolt.patch
0008-use-gtk_tool_item_set_tooltip_text-instead-of-gtk_to.patch
0009-use-gtk_widget_set_-function-instead-of-GTK_WIDGET_S.patch
0010-remove-needless-GtkNotebookPage-from-argument-123.patch
0011-use-gtk_widget_set_can_focus-function-instead-of-GTK.patch
0012-get-GdkDisplay-by-gdk_display_get_default-123.patch
0013-use-GRecMutex-instead-of-GStaticRecMutex-123.patch
0014-use-gtk_widget_get_visible-instead-of-GTK_WIDGET_VIS.patch
0015-use-gtk_widget_has_focus-instead-of-GTK_WIDGET_HAS_F.patch
0016-use-gtkut_widget_get_state-instead-of-GTK_WIDGET_STA.patch
0017-use-gtkut_widget_is_sensitive-instead-of-GTK_WIDGET_.patch
0018-use-g_string_append_printf-instead-of-g_string_sprin.patch

Then we need to consider replacing GtkItemFactory, GtkCList, GtkCTree and so on...

#7 Updated by Hiroyuki Yamamoto 5 months ago

Kentaro HAYASHI wrote:

As a first step, we need to use newer version of API instead of deprecated stuff.
Here is the list of patch a bit supports newer one.

I've attached a patch set bug123-20140601.tar.gz. This archive contains following patches.

Mr Yamamoto, please review and merge into svn HEAD? I've created this patch set for r3404.

Thanks. Just reviewed your patch.

0001-use-g_path_get_basename-instead-of-g_basename-123.patch
- leaks memory in some case
- variable name "basename" should not be used
- possible performance degradation because of malloc()
(should use our original basename() in this case?)

0002-don-t-use-g_strdown-123.patch
- html.c: only tag name and attr_name have to be lowercase, not other parts (attr_value)

0013-use-GRecMutex-instead-of-GStaticRecMutex-123.patch
- g_rec_mutex_init() doesn't seem to be required for static GRecMutex, according to the document

Then we need to consider replacing GtkItemFactory, GtkCList, GtkCTree and so on...

Yes, these are the hardest part :)

#8 Updated by Kentaro HAYASHI 4 months ago

Thanks you for reviewing!

Hiroyuki Yamamoto wrote:

0001-use-g_path_get_basename-instead-of-g_basename-123.patch
- leaks memory in some case
- variable name "basename" should not be used
- possible performance degradation because of malloc()
(should use our original basename() in this case?)

Oops! Actually there are performance degradation,
it spends more than 4 times or so. it is better to use my_basename or something to equivalent one.

0002-don-t-use-g_strdown-123.patch
- html.c: only tag name and attr_name have to be lowercase, not other parts (attr_value)

It is same as 0001, it is better to use my_strdown or something.

0013-use-GRecMutex-instead-of-GStaticRecMutex-123.patch
- g_rec_mutex_init() doesn't seem to be required for static GRecMutex, according to the document

I've got it. Acutually it is documented for static GRecMutex...

I've updated patch 0001,0002,0013.

Also available in: Atom PDF