Skip to main content



      Home
Home » Archived » Lua Development Tools » Range-based indenting?
Range-based indenting? [message #1776973] Thu, 23 November 2017 05:48 Go to next message
Eclipse UserFriend
How does LDT allow to indent just a selection of the code? I've had a look at the formatter.lua that's used and it doesn't seem to have that option, it can only indent the whole block.

I'm looking to use the formatter in my project as well and would like to provide the users with an option to format just a section of the code, so I'm reaching out here for advice!
Re: Range-based indenting? [message #1778801 is a reply to message #1776973] Thu, 21 December 2017 10:34 Go to previous message
Eclipse UserFriend
AFAIK, we format the whole file then we replace only the selected line. As the formatter is not really a formatter but just an indenter this should be ok.

See : https://git.eclipse.org/c/ldt/org.eclipse.ldt.git/tree/plugins/org.eclipse.ldt.ui/src/org/eclipse/ldt/ui/internal/editor/formatter/LuaFormatter.java#n120
Previous Topic:Cant do Existing Install - Repository Empty
Next Topic:How to config LDT to support a big number of functions in one doclua file?
Goto Forum:
  


Current Time: Thu Mar 20 12:12:42 EDT 2025

Powered by FUDForum. Page generated in 0.03075 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top