Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QML Line Numbers #516

Closed
bwiggs opened this issue Mar 7, 2015 · 4 comments
Closed

QML Line Numbers #516

bwiggs opened this issue Mar 7, 2015 · 4 comments

Comments

@bwiggs
Copy link
Contributor

bwiggs commented Mar 7, 2015

The QML frontend needs to support line numbers.

Sublime Text has a setting called line_numbers that is a boolean. See the Sublime Text Unofficial Documentation

See #164 for more context and discussions on the termbox frontend implementation.

@quarnster
Copy link
Member

Since the QML frontend treats each line as a separate item, it should be trivial to add in line numbers. The line number will just be the "index" (or index+1) of the delegate component created by the QML data model.

@bwiggs
Copy link
Contributor Author

bwiggs commented Mar 7, 2015

Is there any backend infrastructure that supports a Gutter? I'm thinking of ST plugins like GitGutter or SublimeLinter that add artifcats next to the line numbers.

@quarnster
Copy link
Member

Gutter icons are specified via view.AddRegions. This is how the syntax highlighting, spelling error-squiggly lines and other text metadata is specified too. It's the job of View.Transform and render.Transform to take all that data into account, usually with the help of Recipie.Transcribe too.

Though it looks like render.Flavour needs to be expanded with an icon field, and render.ViewRegionFlags should probably have a DRAW_ICON const added.

To make it easier for frontends, render.Transform should probably split all DRAW_ICON Flavours so that they are just DRAW_ICON Flavours in a zero sized region containing the start point of the region it's associated with.

@erbridge
Copy link
Contributor

Migrated to limetext/lime-qml#1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants