This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<svg class="svg" version="1.1" xmlns="http://www.w3.org/2000/svg"></svg> | |
<script> | |
$(".svg").svg(); | |
var svg = $(".svg").svg('get'); | |
var myrect = svg.rect(25, 25, 150, '25%', 10, 10, | |
{fill: 'none', stroke: 'blue', strokeWidth: 3, | |
transform: 'rotate(0, 100, 75)'}); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="container"></div> | |
<script> | |
var paper = new Raphael(document.getElementById('container'), 500, 400); | |
var rect = paper.rect(10, 20, 300, 200); | |
rect.animate({ | |
x: 100, | |
y: 50 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<svg id="svg" version="1.1" xmlns="http://www.w3.org/2000/svg"></svg> | |
<script> | |
var s = Snap("#svg"); | |
var rect = s.rect(10, 10, 100, 100); | |
rect.animate({ | |
x: 50, | |
y: 50 | |
}, 1000); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> | |
<script> | |
$(document).ready(function() { | |
var iframe = $('#frame'); | |
$("#frame").ready(function(){ | |
$("#frame").load(function () { | |
data = iframe[0].contentWindow.document.body.innerHTML; | |
if(data == "success"){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public abstract class BaseDomainContext : DbContext | |
{ | |
static BaseDomainContext() | |
{ | |
// ROLA - This is a hack to ensure that Entity Framework SQL Provider is copied across to the output folder. | |
// As it is installed in the GAC, Copy Local does not work. It is required for probing. | |
// Fixed "Provider not loaded" error | |
var ensureDLLIsCopied = System.Data.Entity.SqlServer.SqlProviderServices.Instance; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="//cdn.jsdelivr.net/snap.svg/0.1.0/snap.svg-min.js"></script> | |
<script> | |
var s = Snap("#svg"); | |
var gridSize = 50; | |
var orig = { | |
x: 0, | |
y: 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="//cdn.jsdelivr.net/snap.svg/0.1.0/snap.svg-min.js"></script> | |
<script> | |
var s = Snap("#svg"); | |
var block = s.rect(100, 100, 100, 100, 20, 20); | |
block.attr({ | |
fill: "rgb(236, 240, 241)", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="//cdn.jsdelivr.net/snap.svg/0.1.0/snap.svg-min.js"></script> | |
<script> | |
var s = Snap("#svg"); | |
var origTransform = {}; | |
var block = s.rect(100, 100, 100, 100, 20, 20); | |
block.attr({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is how I would like to use snap.svg's drag method: | |
var block = s.rect(x, y, 100, 100, 20, 20); | |
block.drag({ | |
ondrag: function(dragContext, event) { | |
// drag method here | |
} | |
onstart: function(dragContext, event) { | |
// drag start here | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script src="//cdn.jsdelivr.net/snap.svg/0.1.0/snap.svg-min.js"></script> | |
<script> | |
var s = Snap("#svg"); | |
var block = s.rect(50, 50, 100, 100, 20, 20); | |
block.attr({ | |
fill: "rgb(236, 240, 241)", | |
stroke: "#1f2c39", |
OlderNewer