Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions gui-doc/scribblings/framework/racket.scrbl
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,17 @@
through @racket[end].
}

@defmethod*[(((tabify-selection/reverse-choices (start exact-integer? (send this get-start-position))
(end exact-integer? (send this get-end-position)))
void?))]{
Sets the tabbing for the lines containing positions @racket[start]
through @racket[end], but if there are multiple valid tabbings to cycle through,
this method should cycle through the choices in reverse order. The default
implementation calls @method[racket:text<%> tabify-selection].

@history[#:added "1.77"]
}

@defmethod*[(((tabify-all) void?))]{
Tabs all lines.

Expand Down
8 changes: 8 additions & 0 deletions gui-lib/framework/private/racket.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,7 @@
tabify-on-return?
tabify
tabify-selection
tabify-selection/reverse-choices
tabify-all
insert-return

Expand Down Expand Up @@ -675,6 +676,10 @@
(when (< first-para end-para)
(end-busy-cursor)))))))

(define/public (tabify-selection/reverse-choices [start-pos (get-start-position)]
[end-pos (get-end-position)])
(tabify-selection start-pos end-pos))

(define/public (tabify-all) (tabify-selection 0 (last-position)))
(define/public (insert-return)
(begin-edit-sequence #t #f)
Expand Down Expand Up @@ -1714,6 +1719,8 @@
(λ (x) (send x select-up-sexp)))
(add-edit-function "tabify-at-caret"
(λ (x) (send x tabify-selection)))
(add-edit-function "tabify-at-caret/reverse-choices"
(λ (x) (send x tabify-selection/reverse-choices)))
(add-edit-function "do-return"
(λ (x) (send x insert-return)))
(add-edit-function "comment-out"
Expand Down Expand Up @@ -1827,6 +1834,7 @@
(send keymap map-function key func))

(map "TAB" "tabify-at-caret")
(map "s:TAB" "tabify-at-caret/reverse-choices")

(map "return" "do-return")
(map "s:return" "do-return")
Expand Down
2 changes: 1 addition & 1 deletion gui-lib/info.rkt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

(define pkg-authors '(mflatt robby))

(define version "1.76")
(define version "1.77")

(define license
'(Apache-2.0 OR MIT))
Loading