Class GoDiagram

Description

Class for parsing and analysing the diagram given in SL format.

Located in /sltxt2png.php (line 31)


	
			
Direct descendents
Class Description
GoDiagramPNG Creates PNG image and thumbnail image for a given diagram
GoDiagramSGF Creates SGF file for given diagram.
Method Summary
GoDiagram __construct (string $content)
array getDimensions ()
array getEndPosition ()
string getLinkMap (string $uriname)
array getMarkup ()
array getMoves ([boolean $withTitleMoves = false])
array getStartPosition ()
string getTitle ([boolean $plain = false])
boolean isValid ()
Methods
Constructor __construct (line 66)

Constructor of Diagram class

GoDiagram __construct (string $content)
  • string $content: String containing the diagram in SL syntax

Redefined in descendants as:
getDimensions (line 473)

Return pixel dimensions of diagram image

  • return: Array of width/height
array getDimensions ()
getEndPosition (line 301)

Get goban position at end of diagram (after any moves, without markup)

  • return: Array of goban lines
array getEndPosition ()
getLinkMap (line 451)

Get HTML link map of linked areas in diagram

  • return: HTML of link map
string getLinkMap (string $uriname)
  • string $uriname: HTML map name attribute (URL)
getMarkup (line 317)

Get board markup (but not advanced markup like AR, LN)

  • return: Array of markup info
array getMarkup ()
getMoves (line 389)

Get moves in diagram

  • return: Array of moves
array getMoves ([boolean $withTitleMoves = false])
  • boolean $withTitleMoves: Whether or not moves in title string should be included
getStartPosition (line 288)

Get goban position at start of diagram (before any moves, without markup)

  • return: Array of goban lines
array getStartPosition ()
getTitle (line 416)

Get diagram title

string getTitle ([boolean $plain = false])
  • boolean $plain: Get title as is, or HTML escaped
isValid (line 82)

Returns true, if the diagram is a valid diagram, false otherwise.

boolean isValid ()

Documentation generated on Sat, 31 Oct 2009 11:21:57 +0100 by phpDocumentor 1.4.3