Bring the Web Interface to Swing

I have been fighting with using Swing to create user interfaces for while now.  The advantage with Swing is that it comes with Java and you don’t have to install any additional tools or jars to work with it.  The disadvantage is that you have to code everything manually.  I haven’t found a easy interface for designing GUI’s with Swing.

Since I have done a lot of work with HTML and web development, I thought it might be worth looking at building an HTML front end enveloped by Swing windows.  The only problem is that to make the interface work, I need Javascript.

The LOBO Project looks like my best bet here from my searches so far.  I found it from this Stack Overflow Thread.  It is a pure Java browser.  So, I am thinking that I can embed it in my projects and make that the front-end.

The same thread mentioned using something contained in JDIC.  I think I have used that for notification icons already, so that might be something worth looking into.  I found two other projects: Swingx-WS and WebSwing, but both of those don’t look as promising.

Then, I found Kyle Cordes’ post on using Rhino with Swing.  His code is available, so I need to check it out: Git Hub.

To step back a little, what I really want is a better alternative for creating GUIs.  I found a cool article, that had some other options.  I thought it was interesting that they mentioned having HTML as the front end.  The Visual Editor in Eclipse sounded like something else to check out.  I am going to have explore these instructions for installing more and this tutorial for including custom components.  Other open source options are FormLayoutMaker, Java Object Face, and the Atris Framework.

Another option that is worth looking into is a Chrome Web App.  I found a nice little guide for creating one, or you can read Google’s documentation.  My issue with that is that I need additional access that I don’t think Chrome will give me.

Please comment if you have any ideas.

How Do I Register a Domain Name

I have been trying register a domain name for our church’s website.  We already have someone who is hosting our website, and we just needed a domain name.  Here is what I learned.

I went to register our name on Network Solutions, thinking it was a good company and for some reason wanting to avoid GoDaddy.com.  When it brought up a price over $100, I thought I had better rethink the situation.  After some searching, I found a review on Consumer Search of different domain name services.  It’s recommendation was Name Cheap.com.  Because they were having a sale on the .org names, it was actually cheaper than GoDaddy.com!

I did look at a few other alternatives:

Resources

Wine, MS Office, and Gvfs

They are three different pieces of software, but they can work together:

  • Wine: a tool to run Windows-based software on Linux/Unix operating systems
  • MS Office: the most popular office suites, a tool that needs Wine to run on Linux
  • GVFS: the file system built into Gnome that allows network access

Here is the scenario — you go into the office with your Ubuntu laptop, and your project has an Excel Spreadsheet that you have to use to collaborate on.  Sure, Google Docs would be better for collaborating, but you don’t have a say in the matter.  So, you can either dust off the installation of Windows on the other partition (and install the 500 updates pending), or you can install Office on top of Linux with Wine.

Now, you can get to the spreadsheet in the Gnome File Manager (nautilus) using the network features.  I usually press Ctrl+L to open up the box where you can type in a URL.  Then, I type something like — smb://<server name>/<share>/.  It will probably ask you for your credentials to login to the share, but you should be able to see the xls file.

The next challenge is how do you open it in Office.  Office doesn’t understand the network locations that Gnome knows about.  Really, Wine is what doesn’t know about the network.  Gnome mounts the network share under the .gvfs directory.  Wine doesn’t show the hidden directories, so you can’t get to it.

To solve that problem, I created a network folder that is not hidden, and I linked the .gfvs directory to it:

ln -s ~/.gvfs ~/network

Now, I can see the samba shares in the Office open dialog.  I do still have to go to the File Manager and browse to the share first — that is what mounts it.  Then, I can open it in Office.

I also had an issue with multiple people having the same spreadsheet open.  I opened the spreadsheet, so I should have had the exclusive rights to update it.  Then, my coworker opened the same spreadsheet, and it should have made her’s read only.  Mine was editable like it should have been but so was hers.  Then, when I tried to save it, I gave me an error.  I haven’t experimented with it enough to know if that was a one-time glitch in the network, or if that is something I have to worry about.

I found this bug listing, but my problem was different.  I have written to the share in the past, so I don’t think it is report 0 bytes free.  I found this article that describes what I am doing much better.

The other feature I wish I could have is the ability to drag the files from the file manager to Word or Excel.  It works if the file is on my own computer, but it doesn’t when I am on the network.  Maybe one day…

Great Link: Teaching Open Source

Yesterday, I came across this Teaching Open Source website while reading Max Spevax’s Post.  Here are some of the different things I found on the site:

The textbook is the biggest thing.  Right now, you can go look at Version 0.8 of their textbook.  This is something I need to go through.

Why Can’t the Users Just Rotate Their Screen?

We have a Kodak Zi6 video camera that we have been using to take home videos.  Today, we taped Clay taking some of his first steps, but we did it in portrait instead of landscape.  So, then, the next question is how can we rotate the video, so we don’t have to tell everyone to rotate their screen.

I found this post that suggested using Avidemux.  So, here is what I did:

First, simply open your video with the File > Open command or the Open button on the toolbar.  Next, you need to set the output formats that you want.  I found this post that suggested using MPEG-4 AVC (x264), AAC (Faac), and MP4.  Choosing the right format was rather difficult for me.  Here is what it looks like once you have made the choices:

Next, you need to use a Filter to rotate the video.   So, click the video filters button.

Next, double click on the Rotate filter in the list:

Now, choose your rotation angle:

The Rotate filter should move over to the Active Filters column and should show the rotation angle that you chose:

Now, you simply save your video using the File > Save command or the toolbar.  This will take a few minutes for your computer to process the video and write the file.  I chose an .mp4 extension.

Here is it processing the video:

So, that is it.  Please comment if you have suggestions.  I am still working out the best format to use for sharing with friends and family.  So, if you find something that is better, please let me know.

Resources

WordPress Tip: Adding All Posts to a Tag

In moving my blog across from WordPress.com, I decided I wanted to review all of the posts that I imported. To track which ones I had done and which ones I had not, I created a tag to apply to all of the posts. Then, the challenge was to apply that tag to all of the posts. I couldn’t find anything on the front end, so I decided to try the database.

Here are my explorations in applying that tag:

Read More

What’s Using My CPU and RAM?

My computer has been running slowly periodically, and so, that leads me to ask the question: what is the problem?  Here’s my tool of choice:

Gnome-System-Monitor

You can launch it either from the terminal or with Alt+F2 and typing “gnome-system-monitor”.  You can sort the processes by clicking on the column title.  I find it helpful to sort by the CPU and the Memory.

Resources

Adding Subscribe Button to WordPress

I have one problem with the Garland Theme that I chose for this website is that it doesn’t have a link the RSS feed for readers to subscribe.  No worries: the AddToAny plugin comes to the rescue.  Then, you can add a subscribe button as a widget.

Now, I have the subscribe button on the right side:

When you mouse over it, it opens up with the subscribe options:

Additional Resources: