After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 393586 - [eog-ng] Editable toolbar for EOG
[eog-ng] Editable toolbar for EOG
Status: RESOLVED FIXED
Product: eog
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Claudio Saavedra
EOG Maintainers
Depends on:
Blocks: 374582
 
 
Reported: 2007-01-06 16:57 UTC by Lucas Rocha
Modified: 2007-04-30 20:51 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
simple editable toolbar implementation (140.29 KB, patch)
2007-02-14 05:38 UTC, Claudio Saavedra
none Details | Review
updated patch (142.52 KB, patch)
2007-02-18 04:11 UTC, Claudio Saavedra
committed Details | Review

Description Lucas Rocha 2007-01-06 16:57:17 UTC
We should have editable toolbar in EOG to provide more flexibility to our users.
Comment 1 Claudio Saavedra 2007-02-14 05:38:20 UTC
Created attachment 82512 [details] [review]
simple editable toolbar implementation

So, let's kick the ball.

This patch makes the toolbar in EOG editable. It's pretty simple and it's mostly based on the Evince code. It uses the libegg's editable toolbar, locally copied.

It currently only allows you to edit the EogWindow's toolbar, but maybe we would want to make the fullscreen toolbar editable as well (this could need a bit of thinking because the customization of the toolbar is only possible with drag n drop from and to a dialog, which could be a bit hard when in fullscreen. Opinions?).

We need to decide which items we want to leave by default, and which others will be available. So far, I simply left the current items by default, and left some others available, without thinking too much about it, so that's a topic to be discussed.

(right clicking on the toolbar will give a warning. Please ignore it in this version of the patch).
Comment 2 Lucas Rocha 2007-02-16 11:18:33 UTC
> So, let's kick the ball.

Good. :-)
 
> This patch makes the toolbar in EOG editable. It's pretty simple and it's
> mostly based on the Evince code. It uses the libegg's editable toolbar, locally
> copied.

<snip>

> It currently only allows you to edit the EogWindow's toolbar, but maybe we
> would want to make the fullscreen toolbar editable as well (this could need a
> bit of thinking because the customization of the toolbar is only possible with
> drag n drop from and to a dialog, which could be a bit hard when in fullscreen.
> Opinions?).

Fullscreen toolbar should be the same as the normal toolbar. Not the same case for slideshow toolbar which would be good to have commands like "Play/Pause" or changing the image switching animation (in the future). So, don't worry about this issue.

> We need to decide which items we want to leave by default, and which others
> will be available. So far, I simply left the current items by default, and left
> some others available, without thinking too much about it, so that's a topic to
> be discussed.

Discussion about this should go on bug #310455.

> (right clicking on the toolbar will give a warning. Please ignore it in this
> version of the patch).

Ok.

Some (quick) suggested changes in the patch:

- Put toolbar-editor in a cut-n-paste directory in the root directory (cut-n-paste/toolbar-editor);
- "Toolbar" item in "Edit" menu should come before "Preferences";
- Rename "eog_dot_dir" to "eog_util_dot_dir";
- Indent "eog_util_dot_dir" like other functions in eog-util.h;
- Add fullscreen and slideshow to the available items list.

That's all for now. I didn't have time now for a deep review of the code. I'll do it tonight.
Comment 3 Claudio Saavedra 2007-02-18 04:11:35 UTC
Created attachment 82779 [details] [review]
updated patch

I updated the patch according with your comments, and fixed some minor issues. Summary of changes:

    - Fix several compilation time warnings.
    - Add the toolbar popup which was causing a warning when right clicking in 
      the toolbar. I don't like too much that single item.
    - Apply the changes suggested by Lucas Rocha in bugzilla.
    - Move the toolbar-editor directory inside a new cut-n-paste directory.
Comment 4 Lucas Rocha 2007-04-29 20:23:26 UTC
Made a bunch of fixes and commited in trunk. Thanks Claudio!

2007-04-29  Lucas Rocha  <lucasr@gnome.org>

        Editable toolbar support. Patch from Claudio Saavedra. Fixes
        bug #393586.

        * src/eog-application.[ch] (eog_application_init,
        eog_application_dispose, eog_application_get_toolbars_model,
        eog_application_save_toolbars_model): add centralized toolbar
        model handling for all application windows.
        * src/eog-window.c (eog_window_construct_ui): use toolbar model
        and editable toolbar.
        eog_window_cmd_edit_toolbar, eog_window_cmd_edit_toolbar_cb)
        * src/eog-util.[ch] (eog_util_dot_dir): added function to get
        the user EOG's directory.
        * cut-n-paste/toolbar-editor/*: local copy of editable toolbar
        from libegg.
        * data/eog-ui.xml: added toolbar to Edit menu.
        * data/eog-toolbar.xml: new editable toolbar definition file.
        * configure.ac, Makefile.am, src/Makefile.am: added editable
        toolbar bits to the build.
Comment 5 Claudio Saavedra 2007-04-30 20:41:04 UTC
Lucas, you forgot to 'svn add' the eog-toolbar.xml file. I've committed the one in my latest patch, if you had done any changes, please update it.

(also marking that patch as committed)
Comment 6 Lucas Rocha 2007-04-30 20:51:25 UTC
Shame on me. Thanks! :-)