TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: TopSpace – Scroll above the top line in Emacs

7 pointsby emacs28over 3 years ago
This is an Emacs minor mode I made in my spare time this past year. It lets you scroll above the top line to vertically center top text in Emacs.<p>I made it out of my own necessity for the feature and it is very useful when using Emacs in full-screen with tall&#x2F;large monitors. As monitors have been getting larger for many years now, I&#x27;m actually amazed that this kind of feature isn&#x27;t more available in text editors or other software like internet browsers etc.<p>Let me know what you think or if you have any suggestions!

2 comments

ciprian_craciunover 3 years ago
Indeed it is a nice feature! It&#x27;s useful not only with large monitors, but also when one needs to visually compare two snippets that appear in two files at different offsets close to the beginning &#x2F; end.<p>Although I haven&#x27;t seen it implemented before -- granted I don&#x27;t often investigate text editors -- some editors &#x2F; pagers (`vim`, `less`, Sublime?, etc.) support keeping a number of lines always visible between the cursor and the top &#x2F; bottom of the view; some also support keeping the cursor always centered vertically. But as said, none of them seem to support scrolling past the beginning of the file.<p>BTW, I&#x27;ve just &quot;stolen&quot; your idea and implemented in my own Python-based editor (&lt;<a href="https:&#x2F;&#x2F;github.com&#x2F;volution&#x2F;simple-console-editor" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;volution&#x2F;simple-console-editor</a>&gt;).<p>Thanks! :)
评论 #30420383 未加载
easytigerover 3 years ago
Is the idea that when you are in the top <i>n</i>lines and hit Ctrl-L you&#x27;d still like it to screen center? I know that feeling!
评论 #30419173 未加载