microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
163.63k stars 29.04k forks source link

Let Extensions Change Line Height #63791

Closed MillerMark closed 4 years ago

MillerMark commented 5 years ago

We would like the following extensibility features in VS Code (to match the same extensibility points already shipping in Visual Studio):

  1. The ability to change a line’s height.
  2. The ability to change a line’s caret height (independently of the line height).
  3. The ability to hide special coded text (such as inside a comment) on the line (or paint over it – like an adornment).
  4. The ability to intercept the mouse click/down/up/over events so we can interact with adornments as first class citizens.

Context: These changes would allow extension developers to create plugins that support editing and viewing of rich documents and source code inside VS Code. For example, developers could edit markdown files, seeing embedded images right inside the file, or developers could add LaTeX formulas to comments and see them rendered beautifully as math formulas in the code. This would also allow the CodeRush team to port over the embedded images feature from CodeRush to VS Code as a free plugin.

Sample Embedded Image in Code

Update: This change will help us port other CodeRush features to VS Code, including:

The Debug Visualizer, which shows the values of expressions under the expression, as you step through the code:

Debug Visualizer

LaTeX Formulas in Source Code Comments: LaTeX Formulas

Source Code Comments with custom font sizes: Tiny Comments

Penagwin commented 5 years ago

Is there any update on this? I wish to do something similar.

nhustak commented 5 years ago

I'd love to see this.

vscodebot[bot] commented 4 years ago

We closed this issue because we don't plan to address it in the foreseeable future. You can find more detailed information about our decision-making process here. If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider.

If you wonder what we are up to, please see our roadmap and issue reporting guidelines.

Thanks for your understanding and happy coding!

MihaMarkic commented 4 years ago

The features Mark mentioned looks really awesome and useful in Visual Studio and it's a pity not providing foundations for them in VSCode.

khiron commented 4 years ago

It's disappointing that I can't see projects my team develop using Visual Studio using CodeRush's LaTeX markup in VS Code. We don't need to put a picture of a rocket ship schematic in a code comment, but we do use LaTeX all the time for computational chemistry.

usernamehw commented 4 years ago

There seems to be a very similar feature, which is now in a proposed state: #66418

khiron commented 4 years ago

Yes that would be a kludge that might work, but we'd have to render static images instead of typing LaTeX directly into comments in the code editor which is a better use case.

And it wouldn't enable the other features like debug visualization.

cgbeutler commented 1 year ago

So, is there no way to change a single line's height with an extension or anything? I'd like to write an extension that resizes markdown headers in comments. Sounds like it may be currently impossible...? But it's proving hard to google for.

I'd like to make it so code like this:

// # Profile
// ## Generation Methods
public socialGeneration: "manual" | "roles" | "buy" = "manual";
// Shared across other methods
public socialGen_Feat: SocialFeature | undefined;
// ### Manual Generation
public readonly socialGen_Manual_Stats

Is rendered with different sizes, much like github renders the following markdown:

// # Profile

// ## Generation Methods

public socialGeneration: "manual" | "roles" | "buy" = "manual"; // Shared across other methods public socialGen_Feat: SocialFeature | undefined;

// ### Manual Generation

public readonly socialGen_Manual_Stats

(I already know some folks would dislike the above. I'm looking for info related to this feature request, not to derail this page with feedback on my thang.)

ryanwwest commented 1 month ago

@cgbeutler Did you find out anything more for this? I'd like the same thing with larger-looking headers when viewing Markdown in VS Code's default editor (not some extension that adds its own editor, as then no other extensions work anymore). Plus a way to render links to images inline. But seems like there isn't developer interest.

cgbeutler commented 1 month ago

@cgbeutler Did you find out anything more for this?

Yeah, it's not possible, currently. That's why so many of those extensions do their own window. There might be other editors where it's possible, but I don't know of any. I thought this style would take off more with jupiter notebooks, but, yeah, apparently there's not enough interest. Maybe as Obsidian keeps gaining popularity, it'll eventually leak over.