added getPosition, broke ldoc'ing

This commit is contained in:
Paul Liverman III 2017-04-13 14:28:52 -07:00
parent adb74f476a
commit 65f9715f99
7 changed files with 13 additions and 5 deletions

View File

@ -84,7 +84,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-13 08:11:30 </i> <i style="float:right;">Last updated 2017-04-13 14:28:39 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -491,7 +491,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-13 08:11:30 </i> <i style="float:right;">Last updated 2017-04-13 14:28:39 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -105,7 +105,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-13 08:11:30 </i> <i style="float:right;">Last updated 2017-04-13 14:28:39 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -758,7 +758,7 @@ table.insert element.parent, element.parent\removeChild(element),
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-13 08:11:30 </i> <i style="float:right;">Last updated 2017-04-13 14:28:39 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -126,7 +126,7 @@
</div> <!-- id="main" --> </div> <!-- id="main" -->
<div id="about"> <div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i> <i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.3</a></i>
<i style="float:right;">Last updated 2017-04-13 08:11:30 </i> <i style="float:right;">Last updated 2017-04-13 14:28:39 </i>
</div> <!-- id="about" --> </div> <!-- id="about" -->
</div> <!-- id="container" --> </div> <!-- id="container" -->
</body> </body>

View File

@ -75,6 +75,9 @@ do
end end
return self return self
end, end,
getPosition = function(self)
return self.data.x, self.data.y
end,
setSize = function(self, w, h) setSize = function(self, w, h)
if w then if w then
self.data.w = w self.data.w = w

View File

@ -96,6 +96,11 @@ class element
return @ return @
--- @todo doc me
--- @todo rewrite me to return value based on alignment instead of just x/y
getPosition: =>
return @data.x, @data.y
--- Sets an element's width/height. Fixes alignment if needed. --- Sets an element's width/height. Fixes alignment if needed.
--- @tparam integer w[opt] Width. --- @tparam integer w[opt] Width.
--- @tparam integer h[opt] Height. --- @tparam integer h[opt] Height.