Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #31944 > unrolled thread

Re: Microsoft Word as a Java-IDE

Started byJeff Higgins <jeff@invalid.invalid>
First post2015-07-03 14:09 -0400
Last post2015-07-03 14:09 -0400
Articles 1 — 1 participant

Back to article view | Back to comp.lang.java.programmer

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Microsoft Word as a Java-IDE Jeff Higgins <jeff@invalid.invalid> - 2015-07-03 14:09 -0400

#31944 — Re: Microsoft Word as a Java-IDE

FromJeff Higgins <jeff@invalid.invalid>
Date2015-07-03 14:09 -0400
SubjectRe: Microsoft Word as a Java-IDE
Message-ID<mn6j83$nj7$1@dont-email.me>
On 07/03/2015 01:49 PM, Stefan Ram wrote:
>    I usually write my course notes with Microsoft® Word, so
>    I wrote a small VBA macro to execute the Java programs
>    from within Microsoft Word.
>
>    For example, I might write:
>
>    .--------------------------------------------------------------------
>    |
>   *|   lautet »%n«. Das folgende Programm gibt zwei Zeilen aus
>   *|   und schließt diese ordentlich mit einem Zeilenabschluß ab.
>   *|
>   *|   Main.java
>   *|
>   *|         public class Main
>   *|         { public static void main( final java.lang.String[] args )
>   *|           { java.lang.System.out.printf( "a%nb%n" ); }}
>    |
>    |   Das voranstehende Programm ist gleichbedeutend zu dem
>    |   folgenden Programm.
>    |
>
>    Now, I press Ctrl-O with the cursor in any of the lines
>    marked with an asterisk. It takes about 1 second and the
>    document then looks as follows:
>
>    .--------------------------------------------------------------------
>    |
>    |   lautet »%n«. Das folgende Programm gibt zwei Zeilen aus
>    |   und schließt diese ordentlich mit einem Zeilenabschluß ab.
>    |
>    |   Main.java
>    |
>    |         public class Main
>    |         { public static void main( final java.lang.String[] args )
>    |           { java.lang.System.out.printf( "a%nb%n" ); }}
>    |
>    |   transcript
>    |
>    |         a
>    |         b
>    |
>    |   Das voranstehende Programm ist gleichbedeutend zu dem
>    |   folgenden Programm.
>    |
>
>    A word document might contain several Java-Sources, Ctrl-O
>    will use the one that is »next to the cursor« (the next
>    document after the line of the cursor [= the text caret]).
>
>    Before I had this, I sometimes made changes to the source code
>    and then forgot to check whether it still compiles with the
>    intended semantics. Now I can check this more easily and so
>    I check it more often.
>
>    When the compiler produces an error message, this is also
>    inserted under »transcript«. If there already is a
>    »transcript« below a program, the new transcript will
>    replace the existing one.
>
>    One might extend this in the direction of »literal programming«,
>    where Word will not only execute »main« methods but there
>    also is a means to »execute« freestanding parameterless
>    methods or find and run the unit-tests for a method.
>
JEP 222: jshell: The Java Shell (Read-Eval-Print Loop)
<http://openjdk.java.net/jeps/222>

[toc] | [standalone]


Back to top | Article view | comp.lang.java.programmer


csiph-web