Printing NetLogo source code with colors

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Printing NetLogo source code with colors

bakiunal
Hello
Is it possible to print NetLogo source code with colors?
Thanks
Baki Ünal
Reply | Threaded
Open this post in threaded view
|

Re: Printing NetLogo source code with colors

Robert Gentry Grider
Mr Unal,

This is possible. In NetLogo, go to File > Export... > Export Code. You will be prompted to choose a file location. Once you've selected a file location, NetLogo will save an html fie with the highlighted code to that file.

Thanks,
Robert Grider

On 10/17/17 10:14 AM, [hidden email]<mailto:[hidden email]> wrote:

Hello

Is it possible to print NetLogo source code with colors?

Thanks

Baki ?nal


Reply | Threaded
Open this post in threaded view
|

Re: Printing NetLogo source code with colors

Alan G Isaac-2
In reply to this post by bakiunal
On 10/16/2017 2:28 PM, Baki UNAL [hidden email] [netlogo-users] wrote:
> Is it possible to print NetLogo source code with colors?


As far as I can tell, NetLogo does not provide any print services on Windows.
I have not tried on other OSs.

However, you can use :ToHTML in Vim, along with
https://ccl.northwestern.edu/netlogo/resources/netlogo.vim
and print the result from any browser.

There is also a Pygments plugin, but I haven't tried it:
https://sourceforge.net/projects/netlogo-pygment/

hth,
Alan Isaac
Reply | Threaded
Open this post in threaded view
|

Re: Printing NetLogo source code with colors

Juan Romero-3
In reply to this post by bakiunal
Yes, if you export it as html using:
File->Export-> Export Output
You get the exact code in colors.


Sent from my iPhone

> On Oct 16, 2017, at 11:28 AM, Baki UNAL [hidden email] [netlogo-users] <[hidden email]> wrote:
>
> Hello
>
> Is it possible to print NetLogo source code with colors?
>
> Thanks
>
> Baki Ünal
>
Reply | Threaded
Open this post in threaded view
|

Re: Printing NetLogo source code with colors

Jim Lyons
In reply to this post by bakiunal
In version 6 the answer is happily, yes. Use Export Code… in the File menu. It makes an HTML file with colorized code.

Jim

> On Oct 16, 2017, at 2:28 PM, Baki UNAL [hidden email] [netlogo-users] <[hidden email]> wrote:
>
>
> Hello
>
> Is it possible to print NetLogo source code with colors?
>
> Thanks
>
> Baki Ünal
>
>