fixed outline refresh bug
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / corext / phpdoc / SingleCharReader.java
index 2507032..6bd996e 100644 (file)
@@ -1,9 +1,15 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2003 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials 
+ * are made available under the terms of the Common Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/cpl-v10.html
+ * 
+ * Contributors:
+ *     IBM Corporation - initial API and implementation
+ *******************************************************************************/
 package net.sourceforge.phpdt.internal.corext.phpdoc;
 
-/*
- * (c) Copyright IBM Corp. 2000, 2001.
- * All Rights Reserved.
- */
 
 import java.io.IOException;
 import java.io.Reader;
@@ -48,8 +54,12 @@ public abstract class SingleCharReader extends Reader {
                StringBuffer buf= new StringBuffer();
                int ch;
                while ((ch= read()) != -1) {
-                       buf.append((char)ch);
+                   if (ch=='\n'||ch=='\r') {
+                     buf.append("<br>");
+                   } else {
+                         buf.append((char)ch);
+                   }
                }
                return buf.toString();
        }
-}
\ No newline at end of file
+}