From matley at muppetslab.org Sat Aug 19 20:37:43 2006 From: matley at muppetslab.org (Luigi Panzeri) Date: Sat, 19 Aug 2006 22:37:43 +0200 Subject: [mcclim-devel] draw-arrow with transformation, freetype with fix(ed) fonts Message-ID: <87r6zcea20.fsf@matley.muppetslab.org> Hi all (and good holiday if you are in vacation), i noted two strange behavior, but I am not a clim expert but so sorry if i miss something. 1) draw-arrow* use the line-style-thickness to calculate distances in order to draw the head, but that thickness is not transformed with the current user transformation. So for example: (in-package :clim-user) (define-application-frame foo () () (:panes (app :application :width 1000 :height 1000 :display-function #'display)) (:layouts (default (vertically () app)))) (defun display (frame stream) (declare (ignore frame)) (with-first-quadrant-coordinates (stream 0 1000) (with-scaling (stream 250 250) ;; so now it is 4x4 (draw-line* stream 2 1 2 2.5) (draw-arrow* stream 1 1 1 2.5 :head-length 0.1 :head-width 0.1)))) (run-frame-top-level (make-application-frame 'foo)) i draw a 4x4 grid drawing a line and a parallel arrow (of the same length), but the two drawing is not of the same length. I tried to fix that (see first attachment). 2) in make-text-style i can specify the font family with :fix or :fixed for fixed fonts, but the freetype experimental extension accept only :fix (that is standard-compliant afaik). Do you have suggestion for the delivery of mcclim application (e.g. to avoid the debugger et similia)? -------------- next part -------------- A non-text attachment was scrubbed... Name: patch-draw-arrow.patch Type: text/x-patch Size: 569 bytes Desc: not available URL: From hbabcockos1 at mac.com Thu Aug 24 03:18:36 2006 From: hbabcockos1 at mac.com (Hazen Babcock) Date: Wed, 23 Aug 2006 23:18:36 -0400 Subject: [mcclim-devel] international text help Message-ID: <006A224C-AFAA-4E8F-BAE1-AB57AB1EA66D@mac.com> Hello, I'd like to display some chinese characters in my mcclim application, but I'm not sure how to go about this. I've loaded :mcclim-freetype and tried to follow: http://common-lisp.net/pipermail/mcclim-devel/ 2005-August/004136.html since I have a truetype font that includes chinese characters. (defmethod display-some-pane ((frame translator-frame) stream) (declare (ignore stream)) (let ((pane (get-frame-pane *application-frame* 'some-pane))) (window-clear pane) (with-text-style (pane (make-device-font-text-style (port *application-frame*) "/usr/share/fonts/truetype/ttf-bitstream-vera/VeraBd.ttf")) (draw-text* pane "foo" 10 10)))) gives: The value "/usr/share/fonts/truetype/ttf-bitstream-vera/VeraBd.ttf" is not of type MCCLIM-FREETYPE::FREETYPE-DEVICE-FONT-NAME. [Condition of type TYPE-ERROR] If I use a function that I don't think I'm supposed to use directly: (defmethod display-some-pane ((frame translator-frame) stream) (declare (ignore stream)) (let ((pane (get-frame-pane *application-frame* 'some-pane))) (window-clear pane) (with-text-style (pane (make-device-font-text-style (port *application-frame*) (mcclim-freetype::make-freetype-device-font-name :font-file "/usr/share/fonts/truetype/ttf-bitstream-vera/ VeraBd.ttf" :size 12))) (draw-text* pane "foo" 10 10)))) then it works, but I imagine that this is not the right/supported way. thanks, -Hazen From hocwp at free.fr Sat Aug 26 19:08:24 2006 From: hocwp at free.fr (Philippe Brochard) Date: Sat, 26 Aug 2006 21:08:24 +0200 Subject: [mcclim-devel] [ANN] cl-wav-synth - express noises as you think V2006-08-26 Message-ID: <87r6z3wc0n.fsf@grigri.elcforest> Hi everybody, I'm glad to announce the last public release of cl-wav-synth. cl-wav-synth is a wav sample editor. It comes in two parts, the main library for manipulating wav files and a (Mc)CLIM interface with a full lisp listener, a sample pane editor, a spectrum pane editor and a song pane editor. The wav sample editor is driven from the lisp REPL: you can watch immediately the result of each applied functions. cl-wav-synth comes with some effects as echo, delay, pitch... The spectrum editor is here just for educational purpose. It show the effect of adding sinus together. But it can load spectrum from the sharc project and can be used to produce instruments sounds (the sample amplitude need to be modified to have a real sound). The song editor is a way to express a song. A song is just a list of events to write on a wav file. cl-wav-synth traverses the song list and evaluates the form of each song-sample, if the result is a wav sample, it is merged in the song wav file. Since the last release, there have been many enhancements For samples: - Sample flags (or multiselections) - Sample tones - To produce all the musical range (do, r?, mi... or a, b, c...) from a single sample. - Envelope manipulation (drawing mode) - Players choices (tested under Unix/MacOS/Windows) For songs: - Mouse rectangular selection (move/delete/copy selection) - Undo/Redo system - Grid and snap And some bug fixes (in particular a double redisplay which divided the performances by two (sorry for the bad pub)). You can find more here: http://common-lisp.net/project/cl-wav-synth/ Have fun, and thanks all for your great work with McCLIM ! I'm really amazed how easy it is to make graphical things with clim (once your accustomed to it). Regards, Philippe -- Philippe Brochard http://hocwp.free.fr -=-= http://www.gnu.org/home.fr.html =-=-