Skip to content

Margin starting at 0 instead of 1 #8

@SolarLiner

Description

@SolarLiner
const uint SCI_SETMARGINTYPEN = 0x08C0;
const uint SCI_MARGINSETTEXT = 0x09E2;

Editor.Margins.Margin1.Width = 30;
Editor.NativeInterface.SendMessageDirect(SCI_SETMARGINTYPEN, 1, 4);
for (int i = 0; i < Editor.Lines.Count; i++)
{
    Editor.NativeInterface.SendMessageDirect(SCI_MARGINSETTEXT, i, i.ToString());
}

Is apparently what I have to add. Although I tried on different events and it didn't succeed at printing custom line numbers.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions