view.getTextArea().replaceSelection(buf.toString());
if(stripNewline && buf.length() != 0 && buf.charAt(buf.length()-1) == '\n') buf.setLength(buf.length()-1); buffer.remove(start,end-start); buffer.insertString(start,buf.toString(),null);
	public void actionPerformed(ActionEvent evt)	{		View view = getView(evt);		SyntaxTextArea textArea = view.getTextArea();		String input = textArea.getSelectedText();		Buffer buffer = view.getBuffer();		String command = jEdit.input(view,"execute","execute.cmd");		if(command == null)			return;		StringBuffer buf = new StringBuffer();		for(int i = 0; i < command.length(); i++)		{			switch(command.charAt(i))			{			case '%':				if(i != command.length() - 1)				{					switch(command.charAt(++i))					{					case 'u':						buf.append(buffer.getPath());						break;					case 'p':						buf.append(buffer.getFile()							.getPath());						break;					default:						buf.append('%');						break;					}					break;				}			default:				buf.append(command.charAt(i));			}		}		try		{			Process p = Runtime.getRuntime().exec(buf.toString());			OutputStreamWriter out = new OutputStreamWriter(				p.getOutputStream());			BufferedReader in = new BufferedReader(				new InputStreamReader(p.getInputStream()));			if(input != null)				out.write(input);			out.close();			buf.setLength(0);			String line;			while((line = in.readLine()) != null)			{				buf.append(line);				buf.append('\n');			}			in.close();			view.getTextArea().replaceSelection(buf.toString());		}		catch(IOException io)		{			Object[] error = { io.toString() };			jEdit.error(view,"ioerror",error);		}	}