outline level numbering is wacked?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

outline level numbering is wacked?

Sam Roberts-2
I don't know, maybe I am using it wrong, but it sure doesn't make sense to me!

The coloring is also a screwed up, since it seems to be following the
numbering.

I'm quite enjoying vimoutliner mode other than this.


Here's what I see (NOTES is attached), lines starting with -- are comments:

=======================================
-NOTES
-  Data structure
-    objc is the module table
-      ; objc = {
4      ;   class = lua_objc_lookup_class

-- why is the whole preformatted thing not at the same level, 4?
4      ;   __lua_objc_ids = {
4      ;     <light userdara of value ptr> = <light userdata of id>
4      ;   }
-    id (an obj-c object) is represented as a table:
-      ; id = {}
4      ; id->metatable = {
4      ;   __index = lua_objc_method_lookup
4      ;   __gc    = lua_objc_release
4      ;   __lua_objc_id = <light userdata of id>
4      ; }
3      _ FIXME id uses {}, not ud, so __gc doesn't work!
-- why is this at level 3, its level 4!

-    string, number, and boolean all have the same metatable as an id, minus the __lua_objc_id
-      : its presence is used as a flag, if there is a metatable for the value, its "pointer"
4      : is looked up in objc.__lua_objc_ids, to find an id for this value
-      _ FIXME this doesn't work,
-- why not at level 4, like the line above?


-        _ id is randomly lost


-- why not at level 5?

-          : NSStrings that compare equal will have the same lua pointer
-        _ no garbage collection on this table, it is a memory leak!
-          : not sure how this could be fixed
6      : Why is all this done, anyhow, why not attach appropriate metatables to userdata?

-- level 6? this level was 4 a little while ago!

-  Todo
2    _ use full userdata instead of tables for id

-- how come level 2 is numbered now, but didn't used to be?
-- also, this is level 3, not 2?

2    _ allow NSArray/NSDictionary, NSNumber, NSString, etc., to behave more luaish?
2    _ We could cache results from NSSelectorFromString() - benchmark it...
2    _ Why does an NSAutoreasePool lie and say  respondsToSelector:@selector(retain) is true?
 
 vim:ft=vo_base:ts=2:sw=2:
=======================



_______________________________________________
VimOutliner mailing list
[hidden email]
http://www.lists.vimoutliner.org/mailman/listinfo/vimoutliner

NOTES (1K) Download Attachment
.vimoutlinerrc (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: outline level numbering is wacked?

Peter Princz
Hello Sam,

On 10/03/07, Sam Roberts <[hidden email]> wrote:

> I don't know, maybe I am using it wrong, but it sure doesn't make sense to me!
>
> The coloring is also a screwed up, since it seems to be following the
> numbering.
>
> I'm quite enjoying vimoutliner mode other than this.
>
>
> Here's what I see (NOTES is attached), lines starting with -- are comments:
>

I tried to reproduce the issues you described with little success. I'm
not dare to screw up me vim or vimoutliner resource files, so I just
opened your sample in my vimoutliner and ignored the resource file.

This way, both coloring and indentation works OK for me (gvim 7 on
windows XP, but this is not important, I think.)
I was hoping there are spaces mixed with tabs in your file, which
would probably explain your observations, but it's OK from this
respect too.

The only thing I can imagine is that you are in a bit of a
misunderstanding with the numbers in the leftmost column, they do
*not* reflect *always* the indentation level, the last lines being
exceptions on each level, as far as I observed. I think 'foldcolumn'
is set to '1' for you, I suggest to start to increase it by one until
say 7 and you will get it.

At least for me vim tells me in the statusline the correct indent
value. I haven't investigated how, in theory it should be
'statusline', but that's empty for me, and still it works.

One more thing I'd like to add. I myself managed to screw up indenting
in one of my outline files, but I think it has nothing to do with
vimoutliner, the issue is related to vim7: *if* the encoding is set to
utf8 (multibyte), *and* the first non-whitespace character is a
diacritical one, *then* both indenting and coloring makes a mistake
and shifts the item with one level. The only workaround is to rephrase
my items as to not to start them with diacritical characters... :)

Hope this all helps, sorry if not.

Have a nice day,
  Peter

---
A bug in the hand is better than one as yet undetected.
_______________________________________________
VimOutliner mailing list
[hidden email]
http://www.lists.vimoutliner.org/mailman/listinfo/vimoutliner