prof. dr hab. Włodzimierz Zwonek
Dziekan Wydziału Matematyki i Informatyki
Uniwersytetu Jagiellońskiego
Łojasiewicza 6
30-348 Kraków
Szanowny Panie Dziekanie,
;; modified from pzmq examples | |
(defun hwclient (&optional (server-address "tcp://localhost:5555")) | |
"Translation of http://zguide.zeromq.org/c:hwclient updated for ZMQ 3. | |
Includes some parameters in with-* macros to demonstrate syntax." | |
(pzmq:with-context (ctx :max-sockets 10) | |
(pzmq:with-socket (requester ctx) (:dealer :affinity 3 :linger 100) | |
;; linger is important in case of (keyboard) interrupt; | |
;; see http://api.zeromq.org/3-3:zmq-ctx-destroy | |
(pzmq:connect requester server-address) |
;;; Matrix utilities. | |
(defun matrix= (matrix-1 matrix-2) | |
(destructuring-bind (m1y m1x) (array-dimensions matrix-1) | |
(destructuring-bind (m2y m2x) (array-dimensions matrix-2) | |
(and (= m1y m2y) | |
(= m1x m2x) | |
(loop for y below m1y | |
always (loop for x below m1x | |
always (= (aref matrix-1 y x) |
// based on a keyboard map from an 'xkb/symbols/pl' file | |
default partial alphanumeric_keys | |
xkb_symbols "basic" { | |
// Visualisation and description: http://podziemie.net/xkb/pl | |
// Contact: Michał Górny <zrchos+freedesktop@gmail.com> | |
include "latin" |
(defun ssl-connect () ;; this is a god damn hack | |
(let* ((socket (usocket:socket-connect "lightbringer.furcadia.com" 80)) | |
(stream (usocket:socket-stream socket))) | |
(sleep 1) | |
(loop while (listen stream) | |
for line = (read-line stream nil stream) | |
until (eq line stream) | |
do (format t "S> ~A~%" line)) | |
(format t "C> ~A~%" "starttls") | |
(format stream "starttls~C~C" #\Return #\Linefeed) |
This module contains classes implementing drag and drop functionality inside Qtools UI.
Drag and drop functionality in Qt revolves around MIME types. A single drag can contain data in multiple formats, each of them described by a single MIME type in form of a string.
For simplicity, the mechanism used in this implementation uses only a single MIME type, which, by default, is "application/qtools-mime-data-with-object"
, being the value of *MIME-DATA-WITH-OBJECT-TYPE*
.
;; NOTE: absolutely non-portable | |
* (sb-alien:alien-funcall | |
(sb-alien:extern-alien "syscall" (function sb-alien:unsigned int)) 186) | |
3288 ;; this is the correct PID of the main SBCL thread | |
* (bt:make-thread (lambda () | |
(sb-alien:alien-funcall | |
(sb-alien:extern-alien "syscall" (function sb-alien:unsigned int)) 186))) | |
#<SB-THREAD:THREAD "Anonymous thread" FINISHED values: 3412 {100364B363}> |
This document is meant to be a reference for users and implementers of Kitterspeak, a scripting language for animating graphical shapes used by the MMOSG Furcadia.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
;;;; SWANK-LFE | |
;;;; © Michał "phoe" Herda 2017 | |
;;;; swank.lfe | |
(defmodule swank | |
(export | |
;; ## Utils | |
(curry 2) (curry 3) (curry 4) | |
;; (start_server 1) (stop_server 0) (start_listener 2) |
"This one should be fairly obvious." | |
(defun the-answer-to-life-the-universe-and-everything () | |
(+(*(+(*)(*))(+(*)(*)(*)))(*(*(+(*)(*))(+(*)(*)(*)))(*(+(*)(*))(+(*)(*)(*)))))) | |
"The advanced version of the above." | |
(defun rick ( | |
) ( | |
+ (+ | |
) ( *) ( | |
*) (+) ( *) |