Tuesday, August 30, 2011

The Opera web browser

      Opera is a small (11 MB for the version 11.50) web browser, but it has played a large roll in how we browse the internet today. It pioneered features like mouse gestures, closed tabs, and most notably tabs themselves. Even though Opera was the first to dream up these features it only has about 1% of the total market share of web browsers, internet explorer 8 being the highest.

The psychology to Opera's neglect
Why would a program that paves the way for browsing as we know it be used by only 1% of all of the millions of internet users?

Even if you had a war winning weapon you may still prefer an army. It's that philosophy that causes Opera to be an unpopular browser. You could assume that a browser with more users would have more support, addon writers, and helpers when something goes wrong.

People may also be afraid of the new untested features that Opera produces. Once features trickle down to other browsers they are refined to fit in with the style of that browser. In Opera they are all "fresh out of the oven" and may be scary concepts at first. It's exactly like how the Alpha phase scares some away while others prefer it, other people would prefer beta, others the stable release. Opera would draw from those who like the "alpha" phase of a new feature.

The browser itself
I had been contemplating download opera for a long time before I actually did it. I must have visited the download page 3 time over the past month before I actually decided to test it out. Once I ran it I was very pleased.

Opera loaded in less than 2 seconds, which I expected because it had nothing added onto it. The next thing I noticed were the Panel, Opera Link, Opera Unite, and Turbo mode buttons.

Panel simply opens more options on the left side of the screen. What is shown here can be edited from the Opera menu. Opera link lets you access your bookmarks from anywhere. Opera unite seems to be pretty useful. Once you register an account it gives you some server space to put applications and files on. The turbo button improves browsing for those with slow internet connections by making great use of caching.

Opera caches by default and you may wish to make it check for changed on every reload. You can also do that from the Opera menu.

Compared to other browsers it seems to be extremely fast. Not only in startup, but in page loading as well. Even more so when using Turbo.

Addons, extensions, scripts
Opera is not compatible with firefox or chrome addons. This reduces the amount of addons by a lot. There seem to be plenty of Opera extensions that mimic some of the most popular firefox/chrome ones, but they still are not the same. There is some good news yet to come though. There is no need for Greasemonkey to install your own scripts or download them from userscripts.org You need to make your own folder for the scripts and copy the source code yourself. Then end it with the ".user.js" file extension, put it in the folder, and tell Opera to look in the folder from Opera menu> settings> preferences>Advanced>Content

Thursday, August 25, 2011

My artificial intelligence project

          I have this page that I use to make a list of download links to my programs. All are written in Java and my latest idea isn't different at all. I was thinking a bit about artificial intelligence ever since visiting Cleverbot, the AI that is apparently 42% human when it comes to chatting. The way cleverbot works is it stores what people talk to it about and learns from the conversations. One of the downsides to this is that it learns from untrustable humans from all over the internet. There is no telling what it will talk about.

          My idea didn't start to change this. I just got bored and figured I would make a program that recognized when I greeted it, when I asked it how it's day was, etc; common conversational tactics. But then I realized that I could also make it so that mine learned from talking to me. I rigged it up so that it needs an exact match on a sentence it has seen before to respond, so the learning curb is going to be a long training period. If it encounters something it hasn't seen before it saves the question and asks for a suitable reply. Then, it saves the question and answer in this format: question=answer in a file on your computer. My idea is to eventually have keywords that trigger a response, not an exact match.

         The first version does not even run yet, but it is coming along very quickly. The source code and a compiled version of the program will be available on my java page as soon as the project is up and running. As of right now this is what it looks like. 

This is the source code to the program, and this is the heart of execution where it determines whether to learn or reply.

This is a quick look at a VERY early idea for the GUI. It will still follow along these lines with some modifies buttons and probably a color coded chatting section.

Integrated Development Environments

I am sure that about 90% of programmers and probably around 45% of web developers have used or are currently using an Integrated Desktop Environment (IDE) to do their work. IDEs make it possible to write the code, compile it, and distribute it all from one program. Some of the more advanced IDEs offer code completion and method descriptions.

Let's say you started a new Java project in the Netbeans IDE, my personal favorite. The most commonly used way to output something in java is "System.out.println("Something here");
When you type the "." after "System" it will come up with 31 methods and give the javadoc description for each upon click. After you type or select "out." 41 more methods complete with descriptions come up. This happens for all the classes / methods in the given language. Even ones that you create.

To download netbeans go to netbeans.org
It has support for many language included but not limited to C/C++, java, Most forms of Web, and Ruby.
Another popular IDE is Eclipse, but I downloaded the amd64 version like a fool and cannot run it.

Firefox web browser

I had been using Google Chrome as my web browser until I decided to finally try firefox. 26.8% of all internet users are firefox users according to Wikipedia with only 17.6% using Chrome. I figured that more users could equal more extension support, better ease of use, and more tools than the minimalistic style browser that Chrome is. I was correct.

One of my favorite ideas I saw in firefox were the release channels for beta, current, and alpha. When firefox 5 was released there were already users testing firefox 9, ensuring that the release would mostly be swept of all bugs. You can choose what browser version you want in Linux by added the PPA for whatever version of Firefox you want. The most recent version will gain priority over ones before it. For instance, if you added the Beta PPA and then the Alpha PPA you would be put on the Alpha update channel. You can switch channels at any time by removing the PPA, but I would not recommend that if you are more than a few versions ahead. You could go months without any updates.

      One of the two downsides to firefox that I noticed was speed. Firefox (version 6) is considerably slower than Google Chrome. I have slow internet speed, so any speed counts. But for anyone that has a high speed connection it should barely be a noticeable difference.

     The other issue was the way tabs are run. In Google Chrome every tab is run as a new process, which people complain can eat away at RAM. But it is a wonderful way to do things, because one catastrophic tab failure will not bring down the entire web browser. While it is rare for this to happen in Firefox it has the ability to happen, which is more than enough to scare me when I am doing something critical through the web browser. Firefox makes up for it by saving tabs for opening the next time firefox opens after an unexpected shutdown.


        Extensions are pieces of software created by firefox users that either add functionality or change the way something in the browser or on the web works. Google Chrome has a wide range of extensions, but not nearly as vast as firefox's collection. Some of the extensions are Operating System specific, so Linux / OS X users could be left out.

Some of the more popular extensions are Greasemonkey, Adblock, Firebug, and Speed dial

Greasemonkey allows scripts to be installed and managed. Scripts act similarly to extensions but affect only the way websites work. For a huge collection of scripts visit userscripts.org.

Adblock does exactly what the name makes you think it would do. It blocks ads. Not only does it block them, but it stops them from downloading; saving bandwidth. I am not an adblock user because ads support some of people's favorite websites like hotmail, facebook, and even Blogger.

Firebug is a webpage analyzer.
With it you can view, edit, or add HTML, javascript, and CSS. You can also view how much bandwidth a web page has consumed since you started firebug and you can see how much bandwidth each process takes. It is also great to check to see how fact you can do something or if you even have and internet connection.

Speed dial is like the new tab page from Google Chrome, but they are only websites that you set. It has up to 9 saved pages per group and you have an unlimited amount of groups to make.

Google Chrome / Chromium should be the choice for anyone looking for speed, ease of use, and compatibility. When it is a match between Chrome and Firefox it mostly comes down to preference and how much addon support you want.