OK, I've written a simple implementation of 'spatial versioning'
A database maintains a table 'choices' with 3 columns:
- id (node gnx)
- index (currently selected choice)
- data (a json dict with numeric keys, the value a dict {'h':p.h, 'b':p.b})
The gui element turns out to be not required, in fact, I expect
it would be horrible to have tabs for each choice.
I have 2 buttons: 'right' and 'left'
clicking 'right' increments the index and pulls headline and body from the db,
making a copy of the current node h&b if it's a new index
clicking 'left' decrements the index ...
The Leo file knows nothing about any of this.
A plugin sets up db access and provides one function:
update_choice(p, offset):
p is the current position, offset is 1 or -1
There is lots of room for enhancement, but it already looks to
offer what I've been wanting: access to ad-hoc 'what if' scenarios
instead of the more formal 'and then' world view of VCS.
Thanks,
Kent
On Tue, May 20, 2014 at 12:02 PM, Edward K. Ream <[email protected]> wrote:
> On Mon, Apr 28, 2014 at 9:16 AM, 'Terry Brown
> <[email protected]>' via leo-editor
> <[email protected]> wrote:
>> On Mon, 28 Apr 2014 06:43:45 -0500
>> Kent Tenney <[email protected]> wrote:
>>
>>> Standard version control is time-based, my workmethods seem
>>> to want space-based versioning, IE: the variations I'm considering
>>> are next to each other, not before and after.
>>>
>>> What would suit me would be a tabbed editor pane.
> [snip]
>> Adding UI elements makes this into a non-trivial task.
>
> The words "non-trivial" are an understatement. Some of the most
> difficult code in Leo relates to multiple body editors. Complicating
> that code is something I truly do not want to do.
>
>> What would be quick and easy would be some new commands for keys / buttons:
>
> I agree. Such commands make sense. I will consider such a wishlist
> bug. Otoh, we have dozens such "wishes" now and who knows when any
> will happen.
>
> Edward
>
> --
> You received this message because you are subscribed to the Google Groups
> "leo-editor" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/leo-editor.
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.