Code Formater at Google App Engine

Check this out : http://xzfv.appspot.com/s/about.html

you can use it to format your source code before paste it in the blog.

Just copy your code, submit and copy the result :)

Example :


package org.joke.ui;

import java.net.URL;

import org.eclipse.e4.xwt.XWT;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Event;

public class Hello extends Composite {

public Hello(Composite parent, int style) {
super(parent, style);
}

/**
* @param event
*/
public void onSelectionEvent(Event event) {
MessageDialog.openInformation(getShell(), "test", "Hello");

}
public static void main(String[] args) throws Exception {
URL url = Hello.class.getResource("Hello.xwt");
// Shell shell = XWT.load(url).getShell();
// shell.pack();
// shell.open();
// while (!shell.isDisposed()) {
// if (!shell.getDisplay().readAndDispatch()) {
// shell.getDisplay().sleep();
// }
// }
try {
XWT.open(url);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}

Share this:

ABOUT THE AUTHOR

Superhero with Java powers && Gamer && (Sci-Fi & Star Wars geek) && Bulgarian Java User Group Leader && nerds2nerds podcaster && (link: http://java.beer) java.beer guy ? this : null

3 comments:

markandey said...

I thot, u might give some way to embed into blog post :D

but surprised with presented simplicity!!
good one

JOKe said...

:) I hope any developer know how to embed it into post so that was the reason why I make the post small and simple :).
Anyway there is a lot other ways to do that but this google app is cool :)

My way till now:
1)Copy text from eclipse
2)Paste it into Microsoft Word.
3)Save the file as HTML,
4)Open it with notepad and copy.

the result was nice eclipse like colors and fonts which is better but its too slow.

Jerarckill said...

Excellent!
thank you for the info!