The trunk now contains support for fixed .leo files, as discussed below. All unit tests pass, as do various simple by-hand tests.
Leo suppresses marks, expansion state, orphan bits and current position bits when writing fixed .leo files. As a result, all nodes will be collapsed and the root node will always be selected when Leo opens a fixed .leo file. When writing fixed .leo files, Leo writes fixed, immutable, reasonable defaults for window size, position and body-outline ratio. Specifically, width,height,left,top = 700,500,50,50 and the ratio is 0.5. These values are written so older versions of Leo can read fixed files. You make a file fixed by putting '@bool fixedWindow = True' in the @settings tree of a particular .leo file. The file will be fixed after you save the file, reload the file, and save the file again. Yes, this is clumsy, but it only has to be done once. A toggle-fixed file command doesn't seem that useful: using an @bool node is simple and clear. You can optionally specify the size and position on the screen of fixed .leo files by putting an '@data fixedWindowPosition' node in the @settings tree of myLeoSettings.leo or leoSettings.leo. You should **not** put such a node in the fixed .leo file itself--everyone who opens the file would get that fixed position. The body of the '@data fixedWindowPosition' node should contain something like this: # Must be four entries: width,height,left,top. # Put this in myLeoSettings.leo, **not** in individual .leo files. 1200 800 50 50 Leo uses reasonable defaults for fixed .leo files if this node does not exist, or contains something other than 4 numbers, one per line. Edward P.S. At present, test.leo is fixed. It probably will not remain fixed. The candidates for being fixed include LeoPyRef.leo and LeoDocs.leo. EKR --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "leo-editor" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/leo-editor?hl=en -~----------~----~----~----~------~----~------~--~---
