Difference between revisions of "love.graphics.getLineWidth"

(Fix graphics typo)
(Fixed formatting)
Line 10: Line 10:
 
{{param|number|width|The current line width.}}
 
{{param|number|width|The current line width.}}
  
'''Note:''' This function does not work in 0.8.0, but has been fixed in tip (0.9.0). Use the following snippet to circumvent this;
+
== Notes ==
 +
This function does not work in 0.8.0, but has been fixed in version 0.9.0. Use the following snippet to circumvent this in 0.8.0;
  
 
<source lang="lua">
 
<source lang="lua">

Revision as of 16:10, 7 October 2013

Gets the current line width.

Function

Synopsis

width = love.graphics.getLineWidth( )

Arguments

None.

Returns

number width
The current line width.

Notes

This function does not work in 0.8.0, but has been fixed in version 0.9.0. Use the following snippet to circumvent this in 0.8.0;

love.graphics._getLineWidth = love.graphics.getLineWidth
love.graphics._setLineWidth = love.graphics.setLineWidth
function love.graphics.getLineWidth() return love.graphics.varlinewidth or 1 end
function love.graphics.setLineWidth(w) love.graphics.varlinewidth = w; return love.graphics._setLineWidth(w) end

See Also


Other Languages