rxi / lite

A lightweight text editor written in Lua
MIT License
7.42k stars 353 forks source link

Can I make font bigger? #259

Closed MegDuck closed 3 years ago

MegDuck commented 3 years ago

Can I make font bigger than default? Or where I can change font size?

MegDuck commented 3 years ago

Oh, ok. For all I find it in data/core/style.lua

...

style.font = renderer.font.load(EXEDIR .. "/data/fonts/font.ttf", 14 * SCALE)
style.big_font = renderer.font.load(EXEDIR .. "/data/fonts/font.ttf", 34 * SCALE)
style.icon_font = renderer.font.load(EXEDIR .. "/data/fonts/icons.ttf", 14 * SCALE)
style.code_font = renderer.font.load(EXEDIR .. "/data/fonts/monospace.ttf", 13.5 * SCALE)

...

this line : style.code_font = renderer.font.load(EXEDIR .. "/data/fonts/monospace.ttf", 13.5 * SCALE) is responsible for code font size. Replace 13.5 to your size(float or integer). ( style.icon_font = renderer.font.load(EXEDIR .. "/data/fonts/icons.ttf", 14 * SCALE) responsible for icons in lite. style.font = renderer.font.load(EXEDIR .. "/data/fonts/font.ttf", 14 * SCALE) responsible for files in treeview. style.big_font = renderer.font.load(EXEDIR .. "/data/fonts/font.ttf", 34 * SCALE) responsible for headers(not in code) )

Jipok commented 3 years ago

https://github.com/rxi/lite/issues/258