Loading ...
Sorry, an error occurred while loading the content.
 

increase / decrease indent

Expand Messages
  • Rick Owen
    This may be a known problem. I m not sure where to look to find out. I m using jasspa 2006 with the default key bindings (with minor modifications that
    Message 1 of 3 , Aug 31, 2006
      This may be a known problem.  I'm not sure where to look to find out.
       
      I'm using jasspa 2006 with the default key bindings (with minor modifications that shouldn't have an affect on this issue).
       
      If you highlight a region starting at the end of the region you would like to highlight and then invoke increase (or decrease) indent, it affects the line following the highlighted region.
       
      Thanks,
      Rick.
       

    • Thomas Hundt
      Ha! What a funny bug! You select a region from the bottom up, do Format Decrease Indent, and the last line (only) gets moved. The decrease indent function
      Message 2 of 3 , Aug 31, 2006
        Ha! What a funny bug!

        You select a region from the bottom up, do Format>Decrease Indent, and
        the last line (only) gets moved.

        The decrease indent function must have a loop whereby it starts from
        mark and does a "while if line < point" at the end of it.

        format.emf:
        indent-decrease
        which calls indent-increase

        I think this swap-the-ends-of-the-region functionality is backwards, in
        format.emf around line 384 (I've commented out the incorrect lines):
        set-variable #l1 $window-line
        !if &les #l2 #l1
        ; set-variable #l2 #l1
        ; set-variable #l1 $window-line
        set-variable #l1 #l2 ; TMH FIX
        set-variable #l2 $window-line ; TMH FIX
        !endif
        set-variable #l2 &sub #l2 1

        This seems to work, in my 30s of testing.

        -Th



        Rick Owen wrote, On 8/31/2006 3:52 AM:
        > This may be a known problem. I'm not sure where to look to find out.
        >
        > I'm using jasspa 2006 with the default key bindings (with minor
        > modifications that shouldn't have an affect on this issue).
        >
        > If you highlight a region starting at the end of the region you would
        > like to highlight and then invoke increase (or decrease) indent, it
        > affects the line following the highlighted region.
        >
        > Thanks,
        > Rick.
        >
      • Jon Green
        ... Thanks for this, it certainly was broken and this did fix the problem. I did identify a few more subtle usability aspects surrounding this command with
        Message 3 of 3 , Aug 31, 2006
          Thomas Hundt wrote:
          > Ha! What a funny bug!
          >
          > You select a region from the bottom up, do Format>Decrease Indent, and
          > the last line (only) gets moved.
          >
          > The decrease indent function must have a loop whereby it starts from
          > mark and does a "while if line < point" at the end of it.
          >
          > format.emf:
          > indent-decrease
          > which calls indent-increase
          >
          > I think this swap-the-ends-of-the-region functionality is backwards, in
          > format.emf around line 384 (I've commented out the incorrect lines):
          > set-variable #l1 $window-line
          > !if &les #l2 #l1
          > ; set-variable #l2 #l1
          > ; set-variable #l1 $window-line
          > set-variable #l1 #l2 ; TMH FIX
          > set-variable #l2 $window-line ; TMH FIX
          > !endif
          > set-variable #l2 &sub #l2 1
          >
          > This seems to work, in my 30s of testing.
          >
          > -Th
          >

          Thanks for this, it certainly was broken and this did fix the problem.

          I did identify a few more subtle usability aspects surrounding this
          command with respect to point and mark moving which in some
          circumstances caused the selected region size to change. Hopefully I
          have fixed these now but has meant that the point and mark cannot be
          retained at their original positions in all cases but does mean that the
          command should behave as expected.

          A new patch is available as follows:

          http://www.jasspa.com/dev20060822/rc1_patches/format.emf

          Regards
          Jon.
        Your message has been successfully submitted and would be delivered to recipients shortly.