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
-- Quick launchbar widget for Awesome WM | |
-- http://awesome.naquadah.org/wiki/Quick_launch_bar_widget/3.5 | |
-- Put into your awesome/ folder and add the following to rc.lua: | |
-- local launchbar = require('launchbar') | |
-- local mylb = launchbar("/path/to/directory/with/shortcuts/") | |
-- Then add mylb to the wibox. | |
local layout = require("wibox.layout") | |
local util = require("awful.util") | |
local launcher = require("awful.widget.launcher") |
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
-- Automatically downloads and sets wallpapers from 4walled.com. | |
-- Requires asyncshell (https://gist.github.com/alexander-yakushev/1466863) | |
-- For configuration details see http://awesome.naquadah.org/wiki/Picturesque | |
-- How to use: | |
-- local picturesque = require('picturesque') | |
-- local t = timer { timeout = 3600 } | |
-- t:connect_signal("timeout", picturesque.change_image) | |
-- t:start() | |
local awful = require('awful') |
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
(declaim (optimize (debug 2))) | |
;; Part one. | |
(defun line-number (fname code-loc) | |
(let* ((all-offsets (sb-di::debug-source-start-positions code-loc)) | |
;; Get last item from the array, I haven't found anything | |
;; like 'pop' to do it better. | |
(offset (aref all-offsets (- (length all-offsets) 1)))) | |
(with-open-file (f fname) |
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
function smart_movetoscreen(c, s) | |
local was_maximized = { h = false, v = false } | |
if c.maximized_horizontal then | |
c.maximized_horizontal = false | |
was_maximized.h = true | |
end | |
if c.maximized_vertical then | |
c.maximized_vertical = false | |
was_maximized.v = true | |
end |
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
(ns test.leindroid.sample.main | |
(:use [neko.activity :only [defactivity set-content-view!]] | |
[neko.threading :only [on-ui]] | |
[neko.ui :only [make-ui]]) | |
(:import android.widget.EditText | |
android.net.Uri | |
android.content.Intent)) | |
(declare ^EditText edit | |
^android.app.Activity a) |
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
-- Asynchronous io.popen for Awesome WM. | |
-- How to use... | |
-- ...asynchronously: | |
-- asyncshell.request('wscript -Kiev', function(f) wwidget.text = f:read("*l") end) | |
-- ...synchronously | |
-- wwidget.text = asyncshell.demand('wscript -Kiev', 5):read("*l") or "Error" | |
local awful = require('awful') | |
asyncshell = {} |
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
(ns tetris.core | |
(:import (java.awt Color Dimension BorderLayout) | |
(javax.swing JPanel JFrame JOptionPane JButton JLabel) | |
(java.awt.event KeyListener)) | |
(:use clojure.contrib.import-static deflayout.core | |
clojure.contrib.swing-utils) | |
(:gen-class)) | |
(import-static java.awt.event.KeyEvent VK_LEFT VK_RIGHT VK_DOWN VK_UP VK_SPACE) |
NewerOlder