C, C++, Java String Writer

Miscellaneous programs and scripts, opensource or not, and sometimes, random mathematical stuff.
User avatar
Gamall
Hic sunt dracones
Posts: 4124
Joined: Fri May 26, 2006 11:09 pm
Contact:

C, C++, Java String Writer

Postby Gamall » Sat Sep 01, 2007 7:33 pm

At one point I needed to write looong strings with lots of "\n" and got bored with that.

So I threw this thing together in 5 minutes or so.

It will convert plain text into the string format used by the languages C, C++, Java etc...

This is to say, carriage return = \n

Of course, \n is converted to \\n ;)

StringWriter.jar
Java Executable Archive (with source)
(10.28 KiB) Downloaded 247 times


Not much else to say
StringWriter.PNG
StringWriter.PNG (13.62 KiB) Viewed 3624 times
{<§ Gamall Wednesday Ida §>}
{ Mods and Programs - Mods TES-IV Oblivion }

User avatar
Kafou
Poulidor Gnomonique
Posts: 1501
Joined: Sun Aug 19, 2007 7:17 pm
Location: dans son labo
Contact:

Re: C, C++, Java String Writer

Postby Kafou » Sun Sep 02, 2007 12:14 am

http://www.cppreference.com/escape_sequences.html

T'en as oublié :archange

Ca serait surtout pratique pour les tabulations, les apostrophes et les guillemets (en plus des retours à la ligne et des antislashs), en fait. Le reste on s'en fiche :P

User avatar
Gamall
Hic sunt dracones
Posts: 4124
Joined: Fri May 26, 2006 11:09 pm
Contact:

Re: C, C++, Java String Writer

Postby Gamall » Sun Sep 02, 2007 1:16 pm

Je ne les ai pas "oubliés", c'est juste que je n'en avais pas besoin :lol

C'est au dernier moment, en faisant ça -> viewtopic.php?f=3&t=321, j'avais envie de mettre un texte d'aide GaTeXifié dans l'emplacement des logs, mais la flemme le faire à la main :zzz.

À l'occasion, j'ajouterai le reste. [Ou tu peux le faire en très exactement 72 secondes top-chrono, beta-testing inclus :foufou ]
{<§ Gamall Wednesday Ida §>}
{ Mods and Programs - Mods TES-IV Oblivion }


Return to “Freewares, game mods, Java, C++, OCaml & Maths”

Who is online

Users browsing this forum: No registered users and 9 guests