Zim

tab setting in style.conf ignored

Bug #690151 reported by alienheartbeat
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Zim
Fix Released
Low
Unassigned

Bug Description

I upgraded from 0.28 to 0.49
and now all my wiki pages are misaligned
as the no of chars used for the tab count is not the same
and my setting for it seems to be ignored.

in ~/.config/zim/style.conf
style.conf initially set
 tabstop = 30 # pixels
I changed to
 tabstop = 64 # pixels
to match the setting I had in zim 0.28
(I set this setting to try to match the tab stops in kwrite -
  it worked reasonably well but not perfectly).

This should give me a tab spacing of about 10 chars
but despite changing tabstop to 64 pixels
my tabstops are still at about 4.5 chars
the same as they were with 30 pixels
so all text is hopelessly out of alignment.

nb: I am using the font Liberation Sans 10
as I did in zim 0.28.

Notes:
1. other setting changes I have made to style.conf are honored.
2. changing to another value, eg 80 pixels makes no difference
3. making the same change in /usr/share/zim/style,conf does not help either.

Environment is Kubuntu 10.10, kde 4.5 desktop
INFO: This is zim 0.49
DEBUG: Python version is (2, 6, 6, 'final', 0)
DEBUG: Platform is posix
DEBUG: Zim revision is:
        branch: pyzim-trunk
        revision: 321 <email address hidden>
        date: 2010-11-02 21:14:14 +0100

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote :

Just to be clear, do you only use tabs at the beginning of a line, or also in the middle of some text.

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

I would use it to create text with headers (a topic might be the zim or rsync commands)
topic1 this is line 1
  this is line 2
  this is line 3

nested text with headers (a subtopic might be the Del option in rsync)
  subtopic this is line 21
    this is line 22
    this is line 23

and also columnar text (whre the columns may be phrases
  col11 col12 col13
  col21 col22 col23

the issue happens in situations 1 and 2 above.
zim 0.28 worked fine.

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote : Re: [Bug 690151] Re: tab setting in style.conf ignored

Need to check what we did exactly in 0.28 -- in 0.4x series indenting
is quite different.

On Sat, Dec 18, 2010 at 12:28 PM, undecidable
<email address hidden> wrote:
>
> I would use it to create text with headers  (a topic might be the zim or rsync commands)
> topic1  this is line 1
>                this is line 2
>                this is line 3
>
> nested text with headers (a subtopic might be the Del option in rsync)
>                subtopic        this is line 21
>                                this is line 22
>                                this is line 23
>
> and also columnar text (whre the columns may be phrases
>                col11   col12   col13
>                col21   col22   col23
>
> the issue happens in situations 1 and 2 above.
> zim 0.28 worked fine.
>
> --
> You received this bug notification because you are subscribed to Zim.
> https://bugs.launchpad.net/bugs/690151
>
> Title:
>  tab setting in style.conf ignored
>

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Shouldn't it be the same as in the default text editor?

In any event, I think all text editors treat tabs the same (ie as above)
unless you specify you want tabs replaced by spaces.

I tried explicitly changing the default text editor in the preferences from Default (xdg) to specifically specify kwrite
which is a fairly standard text editor, but it made no difference.
(kwrtie is actually my system default text editor, but I thought it worthwhile to make sure)

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote :

On Mon, Dec 20, 2010 at 2:47 AM, undecidable
<email address hidden> wrote:
>
> Shouldn't it be the same as in the default text editor?
>
> In any event, I think all text editors treat tabs the same (ie as above)
> unless you specify you want tabs replaced by spaces.
>
> I tried explicitly changing the default text editor in the preferences from Default (xdg) to specifically specify kwrite
> which is a fairly standard text editor, but it made no difference.
> (kwrtie is actually my system default text editor, but I thought it worthwhile to make sure)

Default text editor has nothing to do with it, as there is no way to
know what tab settings your default editor is using.

Tabs on the begin of a line are very different from tabs in the middle
since you are editing formatted text, not raw text. So indenting is
handled as a offset of the line start, not by inserting a actual tab
character.

-- Jaap

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Yes, I understand that indenting should be handled as a offset of the line start.
I thik that is what is not working properly now.

I should mention that the misalignment does not happen all the time - sometimes the text is properly aligned. I can find no way to predict when it will be aligned or not, and no way to mess with misaligned text to make it properly aligned.

Please let me know if you want me to test any other patterns.

mc

Changed in zim:
status: New → Confirmed
importance: Undecided → Low
Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Ah pain!!

Could I make a special humble request to raise this to at least 'medium'?

One of the core features of a wiki is (nicely) formatted text.
The honoring of spacing and tabs is a fundamental part of formatted text.

And on a personal note,
I have thousands of pages of zim wiki that are now hopelessly misaligned with the default spacing of 4 (?).
If I want to see what a page looks like, I have to us tools/edit source to open in a text editor.

(690156 is much easier to live with)

mc

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

to try and illustrate the issue more clearly
(and try to rescue this problem from the low priority netherworld)
I attach a screenshot of a typical page under zim 028.

Doesnt seem I can add two attachments,
so I will attach the same page under zim 049 in the next comment.

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

And here is the same page under zim 049.
As you can see, it is misaligned and difficult to see the form of the content.

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote :

Fix committed in rev331.

Changed in zim:
status: Confirmed → Fix Committed
Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Wonderful! thanks very much!

regards

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote :

Fix released in zim 0.50

Changed in zim:
status: Fix Committed → Fix Released
Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Jaap

Just installed zim 0.50 over the top of zim 0.49.

but tabstop= settings in /home/mc/.config/zim/style.conf are still ignored.

Have I missed something?

mc

Revision history for this message
Jaap Karssenberg (jaap.karssenberg) wrote :

On Fri, Feb 18, 2011 at 3:22 PM, undecidable
<email address hidden> wrote:
> Just installed zim 0.50 over the top of zim 0.49.
>
> but tabstop= settings in /home/mc/.config/zim/style.conf  are still
> ignored.
>
> Have I missed something?

The setting is now called "tabs" for real tabs and "indent" for indent
levels at start of line.

See http://www.zim-wiki.org/manual/Help/Config_Files.html.

Regards,

Jaap

Revision history for this message
alienheartbeat (reckless-symmetry) wrote :

Ah, wonderful, it works - thank you.
All my wikis look beautiful again!!

My apology, I did not re-read the documentation when I installed the new vsn.
I did look for a changelist, but on https://launchpad.net/zim it only has the changelists up to 0.49.

will re-read the manuals tomorrow.

thanks & regards
mc

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.