Page 2 of 3

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Tue Oct 26, 2010 9:06 am
by bartoleo
added luadoc
and usage and options

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Tue Oct 26, 2010 12:00 pm
by arquivista
bartoleo wrote:added luadoc
and usage and options
Since this is second version shouldn't this be already alpha 0.0.2 already? Bah, but that don't really matter. :)
Nice work, it's becaming even better.

Tested again in Windows, experienced --usetab and worked well as I can tell in tested code, tested also --noreformat and --lex, didn't found any problems in those.

Suggestion:

--version seems a bit useless/"empty" when you could use instead --help to say that or in alternative when job done output a message with version.
if you continue to use --version at least you could say too who's the author and I suggest give a contact reference or leave forum address for get an updated version

Possible problems:

It's not removing blank spaces/tabs in the end of comment lines

I used --luadoc, (don't know really what's its the purpose of switch) but it transformed this comment:
-- SPACE to restart
to this:
--- SPACE to restart (LUADOC TODO check description)
-- @param key
-- @param unicode
-- @return

It's this supposed to be done?

This was a good well packed update! I think that after you implement a switch for choice of spaces wanted and a kind of space offset in comments in same line than code you covered almost all options and features possible touching perfection (it that exists) :)

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Tue Oct 26, 2010 12:31 pm
by bartoleo
It's not removing blank spaces/tabs in the end of comment lines
Yes.. at the moment I don't touch comments...
but i'll add right trimming
switch for choice of spaces wanted
i'll add number of spaces

on version ...
I'll add something...

the purpose of LuaDoc is to generate a 'small' html documention-site with function/parameters
it needs a 'comment' structure before every function
--- to start
then
--- resume of function
-- description of function
-- @param first_parameter description of parameter...

so if you have a function:
-- SPACE to restart
function function_name(key,unicode)

then the LuaDoc comment is:
--- SPACE to restart (LUADOC TODO check description)
-- @param key
-- @param unicode
-- @return

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Tue Oct 26, 2010 12:34 pm
by arquivista
bartoleo wrote:
the purpose of LuaDoc is to generate a 'small' html documention-site with function/parameters
it needs a 'comment' structure before every function
Thanx for explain that, the comment was indeed before a function. So it works! :)

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Tue Oct 26, 2010 1:18 pm
by bartoleo
added spaces:N option
added right trim on comment
and aded version text...

Re: Graphing similar-UML LUA - alpha 0.0.1 release

Posted: Wed Oct 27, 2010 10:16 am
by arquivista
bartoleo wrote:added spaces:N option
added right trim on comment
and aded version text...
Not much to say, things is going well. trimmed on comments, full credits, spaces seems to work

Maybe found something weird (or not) about code between --[[ and ]]--

ex: to force and test I asked for 20 spaces (--spaces:20) result was:

--[[ is aligned the number of spaces desired (20 spaces)

commented code in between wasnt aligned and retained original indent (tabs and spaces)

]]-- was aligned with a single tab (as original code)

Re: Graphing similar-UML LUA - alpha 0.0.2 release

Posted: Wed Oct 27, 2010 11:01 am
by bartoleo
mmh...
I don't know...
I was thinking that comments were 'untouchable'...
I'll think about...

thank you for testing

Re: Graphing similar-UML LUA - alpha 0.0.2 release

Posted: Wed Oct 27, 2010 11:24 am
by arquivista
bartoleo wrote: I was thinking that comments were 'untouchable'...
You have right on that. However it's always a bit strange that it indents first comment block line leaving others untouched as they are.
Possible option/soluction: leave blocks (not single -- comments) untouched or have option indent all block (and also "treat" the area). Also you can opt for leave first line of a block untouchable too.

EDITED: one reason that's must have an option to treat that blocks is that are usually code so if coder uncomments that later will be always need and forced to prettify since that code by wasn't properly formatted before.

Re: Graphing similar-UML LUA - alpha 0.0.2 release

Posted: Wed Oct 27, 2010 11:35 am
by bartoleo
yes I'll add option to do or not to do it

Re: Graphing similar-UML LUA - alpha 0.0.2 release

Posted: Wed Oct 27, 2010 4:31 pm
by bartoleo
added indenting of block comments with option:

Code: Select all

  --indentblockcomment   enable indenting of block comments (comments
                         starting with --[[ (experimental)
with the option it indents whole block as block (not as code... because my indenting is done via lexer, I have doubts using lexer on comment...)
without the option the blockcomment remains untouched (first line and every line)

it's experimental... so... use it at your own risk