public void set(String s) {
        String line = "";
        boolean toChangeLine = false;
        
        for(int i = 0; i < s.length(); i++) {
            char c = s.charAt(i);
            if(c == '\n') {
                lines.addLast(line);
                line = "";
            }
            else {
                line += c;
            }
        }
        lines.addLast(line);
    }