This file contains 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
/* Convert selection to HTML entitites - danish chars only */ | |
CmdUtils.CreateCommand({ | |
name: "entitize", | |
icon: "http://www.classy.dk/favicon.ico", | |
homepage: "http://www.classy.dk/", | |
author: { name: "Claus Dahl", email: "dee@classy.dk"}, | |
license: "GPL", | |
description: "Translates danish characters to html entities", | |
help: "select text and apply to replace with entitized text", |
This file contains 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
/* | |
Find the 3D coordinates at depth z that project onto planar coordinates (x,y). | |
Screen position is at z-1 in the screen coordinate system, so z should be less than -1 | |
(basically inverse for screenX/screenY) | |
*/ | |
PVector screenToDepth(float x, float y, float z) { | |
// first get the transforms in place | |
PMatrix3D M = (PMatrix3D) g.getMatrix(); | |
PMatrix3D P = (PMatrix3D) ((PGraphics3D) g).getProjection(); | |
P.apply(M); |
This file contains 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
$program = <<'EOP'; | |
$program = <<'EOC'; | |
EXPANDME | |
EOC | |
$program = substr($program,0,-1); | |
$outer = $program; | |
$outer =~ s/EOC(..)$/EOP$1/m; | |
$outer =~ s/EOC$/EOP/m; | |
$outer =~ s/EXPANDME/$program/; | |
print $outer; |
This file contains 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
`mkfifo fifotest` | |
Process.fork do | |
puts "We're going to write a message to a process who will pick it up later" | |
nonblocking = open('fifotest', 'w+') | |
nonblocking.puts "A message for you, Rudy\r\n" | |
nonblocking.flush | |
nonblocking.close | |
puts "Done writing" | |
end |
This file contains 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
def text_to_number(text, n=1000) | |
'0.' + text[0..n].unpack('C*').map{ |i| "%02d" % i}.join('') | |
end |
This file contains 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
We're sorry to hear that you're experiencing problems with your data usage on your Nexus 5 device after updating to the latest Android version. | |
Troubleshooting for Nexus 5 | |
To try and resolve the issue at hand, I have some troubleshooting steps I would like you to try: | |
Conduct a forced shut off by holding Power button and shutting phone down and restarting the device | |
Then, try clearing the cache partition. Here's how: | |
Hold power button for 2 seconds and select 'Power Off' | |
Press and hold the Volume Up and the Volume Down and Power keys at the same time for about 10 seconds. | |
An image of an Android lying on its back will appear. | |
Press the Volume Down key twice until "Recovery mode" appears on the screen. |
This file contains 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
FORM_OPEN_DATE = "2014-03-14 08:00"; | |
FORM_CLOSE_DATE = "2014-11-09 23:30"; | |
RESPONSE_COUNT = "30"; | |
/* Web tutorial: http://labnol.org/?p=20707 */ | |
/* Initialize the form, setup time based triggers */ | |
function Initialize() { | |
deleteTriggers_(); |
This file contains 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
https://github.com/wayneeseguin/rvm/issues/1975#issuecomment-20223263 fixede | |
løste Error running requirements_osx_brew_libs_install openssl098 | |
løsning på The requested url does not exist(22): 'http://production.cf.rubygems.org/rubygems/rubygems-2.0.15.tgz' | |
er | |
wget | |
mv | |
nu ka man installere de rigtige rubygems versioner også... |
This file contains 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
Homebrew is fine | |
but ALWAYS | |
brew install octave --with-docs | |
or no packages will install inside octave (if you don't need packages, never mind the docs) | |
that in turn requires tex | |
you can | |
brew install Caskroom/cask/mactex | |
which builds a text installer that you can then run | |
- or download a binary, prolly much faster | |
After that you should be pretty golden and packages should install |
This file contains 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
// på http://www.evm.dk/arbejdsomraader/vaekst-og-konkurrenceevne/redegoerlse-om-vaekst-og-konkurrenceevne | |
// åben dev console | |
data = [] | |
$.ajaxSetup({complete: function(something) {obj = JSON.parse(something.response); data.push(JSON.parse(obj.d);}}) | |
// og nu fanger man alle data hent på siden, i data - de kan så jsonificers og gemmes elsewhere | |
OlderNewer