Split-pane editing

28 views
Skip to first unread message

Hendrik Boom

unread,
Dec 29, 2020, 5:53:28 PM12/29/20
to us...@racket-lang.org
When editing code in emacs, I oftern split the pane so I have views on two parts of a
file.
Typically, this is so I can see a function definition in one pane at the same time as I
see a corresponding function application in another pane.
Sometimes, this escalates to three panes.

Is there any way to do something similar in drracket?

-- hendrik

Laurent

unread,
Dec 30, 2020, 4:45:47 AM12/30/20
to Hendrik Boom, us...@racket-lang.org
in DrRacket you can hit View|Split, and you can split multiple times.

--
You received this message because you are subscribed to the Google Groups "Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to racket-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/20201229225319.jtxd73vfv4zxok2j%40topoi.pooq.com.

John Kemp

unread,
Dec 30, 2020, 6:38:42 AM12/30/20
to Laurent, Hendrik Boom, us...@racket-lang.org
I have recently been trying to do this too, as it looks like DrRacket *should* allow this…

On Dec 30, 2020, at 4:45 AM, Laurent <laurent...@gmail.com> wrote:

in DrRacket you can hit View|Split, and you can split multiple times.

That’s true, but that doesn’t seem to result in the same behavior as emacs, where it is possible to view two different files side-by-side, rather than one file of definitions in one pane, and the ‘interactions’ in the other pane. I can hide the interactions, but then I seem to have two panes which can only display the same functions and which scroll together, making even looking at two different functions in the same file, impossible (AFAICT).

- johnk

Sorawee Porncharoenwase

unread,
Dec 30, 2020, 7:02:45 AM12/30/20
to John Kemp, Laurent, Hendrik Boom, us...@racket-lang.org

It’s definitely possible to view two portions of a file side by side, using View > Split. See the screenshot below. But it doesn’t seem to be possible to view two different files side by side. Nonetheless, it should be straightforward to create a DrRacket extension to do that.


Screen Shot 2020-12-30 at 3.57.18 AM.png


Laurent

unread,
Dec 30, 2020, 8:18:45 AM12/30/20
to John Kemp, Hendrik Boom, us...@racket-lang.org
On Wed, Dec 30, 2020 at 11:38 AM John Kemp <stable.p...@gmail.com> wrote:
I have recently been trying to do this too, as it looks like DrRacket *should* allow this…

On Dec 30, 2020, at 4:45 AM, Laurent <laurent...@gmail.com> wrote:

in DrRacket you can hit View|Split, and you can split multiple times.

That’s true, but that doesn’t seem to result in the same behavior as emacs, where it is possible to view two different files side-by-side, rather than one file of definitions in one pane, and the ‘interactions’ in the other pane. I can hide the interactions, but then I seem to have two panes which can only display the same functions and which scroll together, making even looking at two different functions in the same file, impossible (AFAICT).

The OP was about splitting the same file. And in DrRacket, you can scroll the two panes independently.

If you want to look at 2 different files, a workaround is to open 2 DrRacket windows and put them side by side.


Reply all
Reply to author
Forward
0 new messages