kemlpy / phamlp

Automatically exported from code.google.com/p/phamlp
0 stars 0 forks source link

Whitespace not preserved for textarea and pre tags when not ugly #98

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
%textarea or %pre with content while not in ugly mode

What is the expected output? What do you see instead?
I expect no additional whitespace to be generated in these special elements.  I 
see whitespace.

What version of the product are you using? On what operating system?
3.2

Fix is to add the following to the beginning of the parseWhitespaceControl 
method of haml/HamlParser.php (line 1221):

        if(in_array($line[self::HAML_TAG], $this->preserve))
            return array('outer' => array('left' => true, 'right' => true), 'inner' => true);

Diff attached.

Original issue reported on code.google.com by cryo...@gmail.com on 27 Apr 2011 at 9:49

Attachments:

GoogleCodeExporter commented 9 years ago
Thanks, needed this. 

Original comment by ize...@gmail.com on 6 Jun 2011 at 8:44