Sublime Forum

Difficulty getting draw_centred to work in ST3

#1

Hi I’m trying to add some left and right margin white-space in normal, windowed editing mode in Sublime Text 3, running on Ubuntu. (I still miss Notational Velocity).

I have set up my ../User/Preferences.sublime-settings file as shown below but it doesn’t seem to have any effect.

[code] {
“color_scheme”: “Packages/Color Scheme - Default/IDLE.tmTheme”,
“draw_centred”: true,
“font_face”: “Calibri”,
“font_size”: 9,
“ignored_packages”:

		"Markdown",
		"Vintage"
	]
}

[/code]

In a related issue, while I was trying to check if drawCentered key was actually set to true I tried view.get_status("draw_centred") but got " as the response in the console.

How do I set a left and right margin in sublime text in windowed mode, and what am I doing wrong?

Thanks

0 Likes

#2

To get the setting for the view, you should use view.settings().get(‘draw_centred’) instead of get_status. See sublimetext.com/docs/3/api_reference.html

0 Likes

#3

Uh, and you have a typo there, is draw_centered not draw_centred !!

0 Likes