Zim

Table rendering broke in 0.65

Bug #1536616 reported by Iank
18
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Zim
Confirmed
Undecided
Unassigned

Bug Description

The rendering of tables has changed between 0.63 and 0.65 (same results on linux and windows builds)
The right-most column in 0.65 is resized to fit the whole width of the screen, on 0.63 it was sized to fit the contents in the same way as the other columns (which I believe is the intended behavior).

Example wiki code that demonstrates the problem.

| | in | out |
|------|------|------|
| Mon | 7.15 | 4.00 |
| Tue | 7.10 | 4.15 |
| Wed | 7.05 | 4.00 |
| Thur | 7.05 | |
| Fri | | |

Revision history for this message
Iank (iank998) wrote :
Download full text (4.8 KiB)

output from zim -D (running on slacko6.3 linux)

# zim -D
INFO: This is zim 0.65
DEBUG: Python version is sys.version_info(major=2, minor=7, micro=5, releaselevel='final', serial=0)
DEBUG: Platform is posix
DEBUG: Zim revision is:
  branch: zim-trunk
  revision: 805 <email address hidden>
  date: 2015-11-01 15:42:45 +0100
DEBUG: Not running from a source dir
DEBUG: Set XDG_DATA_HOME to /root/.local/share
DEBUG: Set XDG_DATA_DIRS to [<Dir: /usr/share>, <Dir: /usr/local/share>]
DEBUG: Set XDG_CONFIG_HOME to /root/.config
DEBUG: Set XDG_CONFIG_DIRS to [<Dir: /etc/xdg>]
DEBUG: Set XDG_CACHE_HOME to /root/.cache
DEBUG: Loading config from: <zim.notebook.VirtualFile object at 0xb69560ec>
DEBUG: Loading config from: /root/Notes/notebook.zim
DEBUG: Wrote /root/.config/zim/notebooks.list
INFO: Using default notebook: file:///root/Notes
DEBUG: Wrote /root/Notes/.zim/tmp
INFO: Remove file: /root/Notes/.zim/tmp
DEBUG: Loading config from: /root/Notes/notebook.zim
DEBUG: Cache dir: /root/.cache/zim/notebook-root_Notes
DEBUG: Index database file: /root/.cache/zim/notebook-root_Notes/index.db
DEBUG: Remote call from 19034: <RemoteMethodCall: 19034: zim.ipc.Server(None).ping((), {})>
DEBUG: Starting server by spawning new process
INFO: Spawning: ['/usr/bin/zim', '--ipc-server-main', '/tmp/zim-root/zim-server-socket', '10'] (cwd: None)
DEBUG: Process started with PID: 19036
DEBUG: Remote call from 19034: <RemoteMethodCall: 19034: zim.ipc.Server(None).ping((), {})>
INFO: Server starting 19036 at /tmp/zim-root/zim-server-socket
DEBUG: Remote call from 19034: <RemoteMethodCall: 19034: zim.ipc.Server(None).ping((), {})>
DEBUG: Remote call returned to 19034: ('ACK', 19036)
DEBUG: Remote call from 19034: <RemoteMethodCall: 19034: zim.ipc.Server(None).has_object((<RemoteObject: zim.gui.GtkInterface(file:///root/Notes)>,), {})>
DEBUG: Remote call returned to 19034: False
DEBUG: Remote call from 19034: <RemoteMethodCall: 19034: zim.ipc.Server(None).init_object((<RemoteObject: zim.gui.GtkInterface(file:///root/Notes)>,), {})>
DEBUG: Wrote <UnixFile: /root/Notes/.zim/tmp>
INFO: Remove file: <UnixFile: /root/Notes/.zim/tmp>
DEBUG: Loading config from: <UnixFile: /root/Notes/notebook.zim>
DEBUG: Cache dir: <Dir: /root/.cache/zim/notebook-root_Notes>
DEBUG: Index database file: <UnixFile: /root/.cache/zim/notebook-root_Notes/index.db>
DEBUG: Opening notebook: <zim.notebook.Notebook object at 0xb660c64c>
DEBUG: Loading config from: <ConfigFile: /root/.config/zim/preferences.conf>
DEBUG: Loading plugin: calendar
DEBUG: Loading plugin: diagrameditor
DEBUG: Loading plugin: gnuplot_ploteditor
DEBUG: Loading plugin: insertsymbol
DEBUG: Loading plugin: linkmap
DEBUG: Loading plugin: printtobrowser
DEBUG: Loading plugin: sourceview
DEBUG: Loading plugin: tableeditor
DEBUG: Registered object table
DEBUG: Loading plugin: trayicon
DEBUG: Trayicon using class: DaemonMainWindowExtension
DEBUG: Gtk version is (2, 24, 20)
DEBUG: Pygtk version is (2, 24, 0)
WARNING: Could not find all icon sizes for the application icon
DEBUG: Loading config from: <ConfigFile: /root/.config/zim/style.conf>
DEBUG: Loading config from: <UnixFile: /root/.cache/zim/notebo...

Read more...

Revision history for this message
Iank (iank998) wrote :

Just tested and actually broke in 0.64

Revision history for this message
PrafullaT (prafulla-t) wrote :

This is culprit revision for this bug.

revno: 796
committer: Jaap Karssenberg <email address hidden>
branch nick: zim-trunk
timestamp: Thu 2015-10-22 18:54:58 +0200
message:
  Refactor size negotiation embedded object
diff:
=== modified file 'zim/gui/objectmanager.py'
--- zim/gui/objectmanager.py 2015-10-16 12:03:53 +0000
+++ zim/gui/objectmanager.py 2015-10-22 16:54:58 +0000
@@ -35,6 +35,8 @@

                'grab-cursor': (gobject.SIGNAL_RUN_LAST, None, (int,)),
                'release-cursor': (gobject.SIGNAL_RUN_LAST, None, (int,)),
+
+ 'size-request': 'override',
        }

        def __init__(self):
@@ -43,13 +45,22 @@
                self._has_cursor = False
                self.vbox = TableVBox()
                self.add(self.vbox)
+ self._textview_width = -1

        def do_realize(self):
                gtk.EventBox.do_realize(self)
                self.window.set_cursor(gtk.gdk.Cursor(gtk.gdk.ARROW))

        def on_textview_size_changed(self, textview, width, height):
- self.set_size_request(width, height)
+ self._textview_width = width
+ self.queue_resize()
+
+ def do_size_request(self, requisition):
+ gtk.EventBox.do_size_request(self, requisition)
+
+ #~ print "Widget requests: %i textview: %i" % (requisition.width, self._textview_width)
+ if self._textview_width > requisition.width:
+ requisition.width = self._textview_width
:

Changed in zim:
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.