:clipping-region and bounding-rectangle

Bug #514218 reported by Kilian Sprotte
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
McCLIM
New
Undecided
Unassigned

Bug Description

I am using :clipping-region to cut off a string on the right
(I could have defined the region more precisely on the left, I am
just using 0 0), so that it basically shows as 123.

(with-output-as-presentation (stream 123 'integer)
    (draw-text* stream "123456789234" 100 100 :text-size 48
  :clipping-region (make-rectangle* 0 0 200 200)))

Should the bounding-rectangle of the resulting output-record be affected?
Unfortunately, it is not.

I will paste the complete demo code below, but I will also attach a screenshot
of the app I am working on, which might be more illustrative.

;;; -*- Mode:Lisp; Syntax:ANSI-Common-Lisp; Coding:utf-8 -*-

(in-package #:clim-user)

(define-application-frame foo ()
  ()
  (:panes (app :application :display-function 'display-app
        :width 600)
   (int :interactor))
  (:layouts (default
  (vertically ()
    app
    int))))

(defun display-app (frame stream)
  (with-output-as-presentation (stream 123 'integer)
    (draw-text* stream "123456789234" 100 100 :text-size 48
  :clipping-region (make-rectangle* 0 0 200 200))))

(define-foo-command (com-print-integer :name t)
    ((obj 'integer))
  (let ((*standard-output* (find-pane-named *application-frame* 'int)))
    (princ obj)
    (terpri)))

(define-presentation-to-command-translator print-integer
    (integer com-print-integer foo)
    (object)
  (list object))

(defun foo ()
  (run-frame-top-level (make-application-frame 'foo)))

Revision history for this message
Kilian Sprotte (kilian-sprotte) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.