<commit_before>/**
* This sketch is for illustration of 
* proxy bug in Processing 2.0.2
* 
* Bug:
* When setting proxy settings in 
*  [preferences.txt], namely:
proxy.host=someproxyname.net
proxy.port=8080
*  these settings won't make PDE use proxy,
*  neither they force sketch
*  to use proxy (Yes, these are two different things).
*
*  HOW TO REPRODUCE:
*  Open [preferences.txt] and add some "fake" proxy configuration
*  which you know will fail. For example make proxy point to 
*  closed port on localhost:
proxy.host=127.0.0.1
proxy.port=4567
   Now open this sketch and run it.
   
   ON BUG EXISTS:  your "fake" proxy setting won't be recognized 
   by the sketch. This sketch would print to console that there's no proxy
   server set up and will succeed in displaying logo.
   
   ON BUG DOESN'T EXIST: you will see in the console message informing you
   that 127.0.0.1 is used as server and you WILL NOT be able to see the image.

*/

String HTTP_urlToTest = "http://processing.org/img/processing2-logo.jpg";

PImage img;
void setup(){
   size(800,600);
   
   String proxyHost = System.getProperty("http.proxyHost");
   String proxyPort = System.getProperty("http.proxyHost");
   print("http.ProxyHost: ");
   println(proxyHost);
   
   print("http.ProxyPort: ");
   println(proxyPort);
   
   
   img = loadImage(HTTP_urlToTest);
   <commit_msg>fixes typo and adds reference to java help<commit_after>/**
* This sketch is for illustration of 
* proxy bug in Processing 2.0.2
* 
* Bug:
* When setting proxy settings in 
*  [preferences.txt], namely:
proxy.host=someproxyname.net
proxy.port=8080
*  these settings won't make PDE use proxy,
*  neither they force sketch
*  to use proxy (Yes, these are two different things).
*
*  HOW TO REPRODUCE:
*  Open [preferences.txt] and add some "fake" proxy configuration
*  which you know will fail. For example make proxy point to 
*  closed port on localhost:
proxy.host=127.0.0.1
proxy.port=4567
   Now open this sketch and run it.
   
   ON BUG EXISTS:  your "fake" proxy setting won't be recognized 
   by the sketch. This sketch would print to console that there's no proxy
   server set up and will succeed in displaying logo.
   
   ON BUG DOESN'T EXIST: you will see in the console message informing you
   that 127.0.0.1 is used as server and you WILL NOT be able to see the image.

*/

String HTTP_urlToTest = "http://processing.org/img/processing2-logo.jpg";

PImage img;
void setup(){
   size(800,600);
   
   // getting proxy settings as described in 
   // @see http://docs.oracle.com/javase/6/docs/technotes/guides/net/proxies.html
   String proxyHost = System.getProperty("http.proxyHost");
   String proxyPort = System.getProperty("http.proxyPort");
   print("http.ProxyHost: ");
   println(proxyHost);
   
   print("http.ProxyPort: ");
   println(proxyPort);
   
   
   img = loadImage(HTTP_urlToTest);
   
{'fraction_non_alphanumeric': 0.09642733263961152, 'fraction_numerical': 0.02115851543531044, 'mean_word_length': 3.4852255054432346, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 4, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4300845', 'n_tokens_mistral': 954, 'n_tokens_neox': 900, 'n_words': 331}