Tuesday, August 31, 2010

WebcamMax


A slick interface, simple installation, and tons of customization features make WebcamMax an excellent option for using your Webcam with multiple programs simultaneously.
Compatible with 16 programs, including CamFrog, PalTalk, all the major chatware apps like AIM, ICQ, Yahoo, and MSN, and others, WebcamMax is hassle-free. When installing the program, there are no pesky toolbars to opt-out of, and in fact the program lets you set it as the primary Webcam source for its list of compatible programs during setup. The interface is intuitive and pleasant to use, as well as being well-polished and professional. No worries here about paying for a program that doesn't look the part. We experienced no drags on system resources, but older machines could have problems.
There are freeware programs that offer a very similar experience to WebcamMax, but this app definitely has the larger built-in image library and the smoothest experience.

Monday, August 30, 2010

Calculate page size and viewport position

Basically every browser except Internet Explorer agrees where the dimensions information is located. Can’t say that I’m particularly surprised, Microsoft has made it their mission to complicate these things.
For a nice visual list of available properties and browser support check out the W3C DOM CSS Object Model Compatibility article on QuirksMode. It’s a very nice list of many useful properties and methods as well as a chart of what browsers support them and how effective their support is.

View port dimensions

I found three possible objects that contain the view port size information. In most browsers the self object has the properties of innerWidth and innerHeight. However Internet Explorer has two other objects, IE6 keeps this information in the document.documentElement object and all new IEs use thedocument.body object. These objects have a clientWidth and clientHeight property.

Document dimensions

Once again, I found three different ways to get the document measurements. Most browsers agree that this information is stored in the document.body object. However Firefox’s best measurement of total document height seems to be window.innerHeight + window.scrollMaxY. The rest of the browsers respond to the scrollWidth/scrollHeight or offsetWidth/offsetHeight.

Scroll offset

Last but not least is the scroll offset, and again three different possible locations for this information. The general consensus is that scroll offset can be found in the pageYOffset and pageXOffset properties of the self or window objects. However IE uses scrollTop and scrollLeft properties on thedocument.body or document.documentElement objects.

Rails 3.0 Released (And 22 Free Videos To Bring You Up To Speed)

Rails 3.0 has been underway for a good two years, so it’s with immense pleasure that we can declare it’s finally here. We’ve brought the work of more than 1,600 contributors together to make everything better, faster, cleaner, and more beautiful.
David Heinemeier Hansson

DHH rings the bell and announces that Rails 3.0 (final) has been released after two years of determined effort by the Rails core team (and, significantly, Merb team members, since Rails 3.0 is heavily influenced by the Merb merger). Grab it now with gem install rails --version 3.0.0 or, if you're in no rush, Rails 3.0.1 might come along within a week or two.

The Videos

DHH gives a quick roundup of some of Rails 3's new features but like Emma Watson's head PhotoShopped onto yet another naked body, it's nothing you haven't seen before. If you're really fresh to Rails 3.0, though, Gregg does an admirable job of boiling everything down into a digestible format with his (free!) Dive Into Rails 3.0 screencast series:
Ryan Bates has also produced a fistful of his typically succinct but precise RailsCasts videos on a wide array of Rails 3.0 topics. Ryan always focuses on code and practicalities so these are a good place to start if you want to follow along and do some coding yourself:
If you don't like videos, still follow the links, because there are links to the ASCIIcasts regular HTML versions of the Railscasts videos. These are regular blog posts that you can follow at your own pace.

Or some books

Michael Hartl's Rails Tutorial book is the #1 (and only, in my opinion) place to start when it comes to books about learning Rails 3.0. Not only is it available to read for free online, but you can buy a well formatted PDF too. It's an amazing piece of work and, unusually, walks you through building a Rails app from start to finish with testing. If you want to just read one book/site and feel like a Rails 3.0 master by the end of it, pick RailsTutorial.org.
If you speak German, though, check out this "Ruby on Rails 3" book by Michael Voigt and Stefan Tennigkeit. It's one of the first Rails 3.0 specific books to hit the presses.

Or just dive into some code

If you want to just "get started" and check out a working Rails 3.0 application, try Daniel Kehoe's Rails3-Subdomain-Devise app. It's a basic Rails 3.0 app that demonstrates using the Devise authentication system, as well as custom subdomain access. Not just that, but Daniel has put together a walkthrough of how the app works and how it was put together.

http://www.rubyinside.com/rails-3-0-released-and-22-free-videos-to-bring-you-up-to-speed-3733.html?utm_source=feedburner&utm_medium=email&utm_campaign=Feed%3A+RubyInside+%28Ruby+Inside%29

Sunday, August 22, 2010

QuickSand


Reorder and filter items with a nice shuffling animation. Just specify source container and destination collection which will replace the source collection. New elements will appear with fancy scaling+alpha effect, deleted elements (non-existant in destination collection) will scale out and rearranged items will move to their destination positions.

http://razorjack.net/quicksand/

PaintbrushJS

PaintbrushJS is a lightweight, browser-based image processing library
that can apply various visual filters to images within a web page.

You use it by applying a class to an element on the page and setting
a few parameters with some extra HTML attributes. If the element is
an img or it has a background-image set in your CSS, PaintbrushJS
will create a temporary canvas element and manipulate the image
there, before finally saving it back out to the original element.

See PaintbrushJS in action: http://mezzoblue.github.com/PaintbrushJS/demo/
Documentation: http://wiki.github.com/mezzoblue/PaintbrushJS/documentation
PaintbrushJS on GitHub: http://github.com/mezzoblue/PaintbrushJS

Polymaps

Polymaps is a free JavaScript library for making dynamic, interactive maps in modern web browsers.

Polymaps provides speedy display of multi-zoom datasets over maps, and supports a variety of visual presentations for tiled vector data, in addition to the usual cartography from OpenStreetMap, CloudMade, Bing, and other providers of image-based web maps.
Because Polymaps can load data at a full range of scales, it’s ideal for showing information from country level on down to states, cities, neighborhoods, and individual streets. Because Polymaps uses SVG (Scalable Vector Graphics) to display information, you can use familiar, comfortable CSS rules to define the design of your data. And because Polymaps uses the well known spherical mercator tile format for its imagery and its data, publishing information is a snap.

http://polymaps.org/

Monday, August 16, 2010

Fossil. Simple, high-reliability, distributed software configuration management

There are plenty of open-source version control systems available on the internet these days. What makes Fossil worthy of attention?
  1. Bug Tracking And Wiki - In addition to doing distributed version control like Git and Mercurial, Fossil also supports distributed bug tracking and distributed wiki all in a single integrated package.
  1. Web Interface - Fossil has a built-in and easy-to-use web interface that simplifies project tracking and promotes situational awareness. Simply type "fossil ui" from within any check-out and Fossil automatically opens your web browser in a page that gives detailed history and status information on that project.
  1. Autosync - Fossil supports "autosync" mode which helps to keep projects moving forward by reducing the amount of needless forking and merging often associated with distributed projects.
  1. Self-Contained - Fossil is a single stand-alone executable that contains everything needed to do configuration management. Installation is trivial: simply download a precompiled binary for Linux, Mac, or Windows and put it on your $PATH. Easy-to-compile source code is available for users on other platforms. Fossil sources are also mostly self-contained, requiring only the "zlib" library and the standard C library to build.
  1. Simple Networking - Fossil uses plain old HTTP (with proxy support) for all network communications, meaning that it works fine from behind restrictive firewalls. The protocol is bandwidth efficient to the point that Fossil can be used comfortably over a dial-up internet connection.
  1. CGI Enabled - No server is required to use fossil. But a server does make collaboration easier. Fossil supports three different yet simple server configurations. The most popular is a 2-line CGI script. This is the approach used by the self-hosting fossil repositories.
  1. Robust & Reliable - Fossil stores content using an enduring file format in an SQLite database so that transactions are atomic even if interrupted by a power loss or system crash. Furthermore, automatic self-checks verify that all aspects of the repository are consistent prior to each commit. In nearly three years of operation, no work has ever been lost after having been committed to a Fossil repository.
http://www.fossil-scm.org/fossil/doc/tip/www/index.wiki

ØMQ. Fastest. Messaging. Ever.

ØMQ looks like an embeddable networking library but acts like a concurrency framework. It gives you sockets that carry whole messages across various transports like inproc, IPC, TCP, and multicast. You can connect sockets N-to-N with patterns like fanout, pubsub, task distribution, and request-reply. It's fast and small enough to be the fabric for clustered products. Its asynchronous I/O model gives you scalable multicore applications, built as asynchronous message-processing tasks. It has over twenty language APIs and runs on most operating systems. ØMQ is open source and fully supported by iMatix.

http://www.zeromq.org/start

Monday, August 9, 2010

To defeat Rails' conspiracy to have you not use the JSON gem.
See activesupport-2.3.8/lib/active_support/json/encoding.rb line 92 gRRRRRRRRRRRRRRRR!!!
Call UseJsonGemInRails.save_json_gem_to_json in your RAILS_ROOT/config/preinitializer.rb file.
Then set up an initializer and call UseJsonGemInRails.reload_json_gem_to_json in it.

class UseJsonGemInRails
  class << self
    def save_json_gem_to_json
      require 'json'
      classes.each do |klass|
        klass.class_eval do
          alias_method :to_json_from_gem, :to_json
        end
      end
    end
    def reload_json_gem_to_json
      (classes + [ActiveSupport::JSON::Variable]).each do |klass|
        klass.class_eval do
          alias_method :to_json, :to_json_from_gem
        end
      end
    end
    def classes
      [
        Object,
        Hash,
        Array,
        String,
        Numeric,
        Float,
        Integer,
        Regexp,
      ]
    end
  end
end

http://gist.github.com/461938

Platypus

Platypus is a developer tool for the Mac OS X operating system. It can be used to create native, flawlessly integrated Mac OS X applications from interpreted scripts such as shell scripts or Perl and Python programs. This is done by wrapping the script in an application bundle directory structure along with an executable binary that runs the script.

http://www.sveinbjorn.org/platypus

Wednesday, August 4, 2010

Rake RDocTask with all of the options stubbed out

# Rake RDocTask with all of the options stubbed out.
Rake::RDocTask.new(:rdoc) do |rd| 
  1. # rd.external # run the rdoc process as an external shell
  2. # rd.main = "name" # 'name' will be the initial page displayed
  3. # rd.rdoc_dir = "html" # set the output directory
  4. # rd.rdoc_files = [] # List of files to include in the rdoc generation
  5. # rd.template = "html" # Name of the template to be used by rdoc
  6. # rd.title = "" # Title of the RDoc documentation
  7. # rd.options << "--accessor accessorname[,..]" # comma separated list of additional class methods that should be treated like 'attr_reader' and friends.
  8. # rd.options << "--all" # include all methods (not just public) in the output
  9. # rd.options << "--charset charset" # specifies HTML character-set
  10. # rd.options << "--debug" # displays lots on internal stuff
  11. # rd.options << "--diagram" # Generate diagrams showing modules and classes using dot.
  12. # rd.options << "--exclude pattern" # do not process files or directories matching pattern unless they're explicitly included
  13. # rd.options << "--extension new=old" # Treat files ending with .new as if they ended with .old
  14. # rd.options << "--fileboxes" # classes are put in boxes which represents files, where these classes reside.
  15. # rd.options << "--force-update" # forces to scan all sources even if newer than the flag file.
  16. # rd.options << "--fmt format name" # set the output formatter (html, chm, ri, xml)
  17. # rd.options << "--image-format gif/png/jpg/jpeg" # Sets output image format for diagrams. Default is png.
  18. # rd.options << "--include dir[,dir...]" # set (or add to) the list of directories to be searched.
  19. # rd.options << "--inline-source" # Show method source code inline, rather than via a popup link
  20. # rd.options << "--line-numbers" # Include line numbers in the source code
  21. # rd.options << "--merge" # when creating ri output, merge processed classes into previously documented classes of the name name
  22. # rd.options << "--one-file" # put all the output into a single file
  23. # rd.options << "--opname name" # Set the 'name' of the output. Has no effect for HTML format.
  24. # rd.options << "--promiscuous" # Show module/class in the files page.
  25. # rd.options << "--quiet" # don't show progress as we parse
  26. # rd.options << "--ri" # generate output for use by 'ri.' local
  27. # rd.options << "--ri-site" # generate output for use by 'ri.' sitewide
  28. # rd.options << "--ri-system" # generate output for use by 'ri.' system wide, for Ruby installs.
  29. # rd.options << "--show-hash" # A name of the form #name in a comment is a possible hyperlink to an instance method name. When displayed, the '#' is removed unless this option is specified
  30. # rd.options << "--style stylesheet url" # specifies the URL of a separate stylesheet.
  31. # rd.options << "--tab-width n" # Set the width of tab characters (default 8)
  32. # rd.options << "--webcvs url" # Specify a URL for linking to a web frontend to CVS. 
end