background preloader

Programming

Facebook Twitter

Discover Everything through Code. Laravel Cheat Sheet. SVG Zoom Effects With Internal JavaScipt. March 15, 2014 • By Joe Howard • In Web Development SVG is such a great web technology with so much potential for all kinds of things.

SVG Zoom Effects With Internal JavaScipt

Did you know you can run “inline” JavaScript within SVG markup? I’ve been experimenting a lot with SVG over the past few weeks with the aim of trying to expand its uses beyond just icons. Today I’ll be running through another experiment using inline JavaScript within SVG for some simple DOM manipulations. The demo uses SVG clipping masks along with some JS to create the effect. Rather than go through the complexities of the demo itself, I’ll run through a simplified version of the principle and how everything works (that seemed to work quite well with the previous demo). You can check out the demo below or download the source files if you want to take a look at the specifics. Download Source Files View Demo How the effect works Before we get started, let’s take a brief look at how things work. We have a square and a circle Duplicate the circle JavaScript. Light Table Plugin Tutorial - Jakub Arnold Blog. I've been playing around with Light Table since the day its source code was released (even made a tiny Ruby plugin).

Light Table Plugin Tutorial - Jakub Arnold Blog

First of all, Light Table is based on the BOT architecture. Which means there are three core concepts: behaviors, objects and tags. If you have any experience with Node.js or event driven programming, you'll have an easy time understanding the concepts. Imagine you have a button which listens on a click event and displays a notice to the user when it's clicked Using jQuery that could be as simple as the following $(".my-button").click(function() { showProgress("I'm doing some heavy lifting");}); But there are problems with this approach, especially from the Light Table's point of view. Here's an implementation in ClojureScript. (ns lt.tutorial (:require [lt.object :as object] [lt.objs.tabs :as tabs] [lt.objs.statusbar :as statusbar] [lt.objs.notifos :as notifos] [lt.util.js :as util]) (:require-macros [lt.macros :refer [behavior defui]]))

GetClojure. Aysylu/loom. Marginalia. A jQuery plugin for extracting dominant colors from images and applying it to its parent. Highlight.js. Robflaherty/jquery-annotated-source. 4clojure – Welcome! Practical: An MP3 Database. Copyright © 2003-2005, Peter Seibel In this chapter you'll revisit the idea first explored in Chapter 3 of building an in-memory database out of basic Lisp data structures.

Practical: An MP3 Database

This time your goal is to hold information that you'll extract from a collection of MP3 files using the ID3v2 library from Chapter 25. You'll then use this database in Chapters 28 and 29 as part of a Web-based streaming MP3 server. Of course, this time around you can use some of the language features you've learned since Chapter 3 to build a more sophisticated version. The Database The main problem with the database in Chapter 3 is that there's only one table, the list stored in the variable *db* . This time you'll solve both problems by defining a class, table , to represent individual database tables.

(defclass table () ((rows :accessor rows :initarg :rows :initform (make-rows)) (schema :accessor schema :initarg :schema))) Defining a Schema (defgeneric make-column (name type &optional default-value)) Inserting Values. Learn Clojure. Clojure - home. Structure and Interpretation of Computer Programs. Programming Methodology (Stanford) Light Table.