Return-Path: Delivered-To: apmail-pivot-user-archive@www.apache.org Received: (qmail 97668 invoked from network); 10 Sep 2010 19:39:29 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 10 Sep 2010 19:39:29 -0000 Received: (qmail 26774 invoked by uid 500); 10 Sep 2010 19:39:28 -0000 Delivered-To: apmail-pivot-user-archive@pivot.apache.org Received: (qmail 26757 invoked by uid 500); 10 Sep 2010 19:39:28 -0000 Mailing-List: contact user-help@pivot.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@pivot.apache.org Delivered-To: mailing list user@pivot.apache.org Received: (qmail 26749 invoked by uid 99); 10 Sep 2010 19:39:28 -0000 Received: from Unknown (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Sep 2010 19:39:28 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=FREEMAIL_FROM,HTML_MESSAGE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of cbartlett.x@gmail.com designates 209.85.215.182 as permitted sender) Received: from [209.85.215.182] (HELO mail-ey0-f182.google.com) (209.85.215.182) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Sep 2010 19:39:03 +0000 Received: by eyx24 with SMTP id 24so2328925eyx.13 for ; Fri, 10 Sep 2010 12:38:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=exhUS8qVK874GcCsoPEGg0Ns5VHxN8BjEPY46O7T1H8=; b=BMYEZ3WlmMR8WOcvz0ywu3XIx+krPov/3Vc3N+1WU0ukn8DsL1ELetD5mK2SB5HNdZ rhrLatenl921WKdIHszs9jZR4KOCpkkOfeJGwArSdtcw4vy5/qLSPRQRMaqY9Qxg92zf Lw1uAGy8UZEtd2I5K0r77Mep8H/pxsaj6DSnE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=f3aHr7xKyYyD1aQmZhbGYES4h0tqJsZ6PTqnn1DGEZHymv8D3aiqEI8azP+RZ/g9Sa e6KMe36qrdhSMczYaj1xRS/EMtmbSokOyF5ALVM2oOFSmG9s6M1qAa9azpaPnf9l97Cl SLajjhA5Lo98SvDtiREaxJX1VbAozrrJ1ULgw= MIME-Version: 1.0 Received: by 10.14.47.10 with SMTP id s10mr668915eeb.35.1284147523159; Fri, 10 Sep 2010 12:38:43 -0700 (PDT) Received: by 10.14.22.78 with HTTP; Fri, 10 Sep 2010 12:38:42 -0700 (PDT) In-Reply-To: References: <7678D1CC-EBA2-4690-A4E1-2C0E5DF749C9@rbwhitcomb.com> Date: Sat, 11 Sep 2010 02:38:42 +0700 Message-ID: Subject: Re: Tool bar separators? From: Chris Bartlett To: user@pivot.apache.org Content-Type: multipart/alternative; boundary=90e6ba6154e4f51435048fece45f X-Virus-Checked: Checked by ClamAV on apache.org --90e6ba6154e4f51435048fece45f Content-Type: text/plain; charset=ISO-8859-1 But could the rotation code be part of the Separator component's paint/layout/'whatever magic happens when painting' code? paint() { if (orientation = VERTICAL) { // Swap the width & height values for the purposed of painting // ie, 20x100 would be painted horizontally within the bounds of 100x20 } // Draw the component horizontally as normal, but to an image/buffer rather than the GUI if (orientation = VERTICAL) { // Rotate and possibly re-align the previously rendered image } // Paint the image to the GUI } On 11 September 2010 02:26, Greg Brown wrote: > Good idea, but it wouldn't work. Decorators don't change the bounds of a > component. They only augment its appearance. > > On Sep 10, 2010, at 3:22 PM, Chris Bartlett wrote: > > > On 10 September 2010 19:05, Greg Brown wrote: > >> I was actually thinking that a new BoxPane.Divider class might be a better >> way to go. Separator has a "title" property that would be hard to support in >> a vertical orientation. Divider could simply mirror the orientation of the >> containing box pane. >> >> Is it worth considering using some sort of rotation decorator that would > rotate a horizontal Separator, including any title property +/- 90 degrees > to create a vertical one? > > Chris > > > > --90e6ba6154e4f51435048fece45f Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
But could the rotation code be part of the Separator component's p= aint/layout/'whatever magic happens when painting' code?
<= div>
paint() {

=A0 =A0 if (orie= ntation =3D VERTICAL) {
=A0 =A0 =A0=A0 =A0// Swap the width & height values for the purpos= ed of painting
=A0 =A0 =A0 =A0 // ie, 20x100 would be painted hor= izontally within the bounds of 100x20
=A0 =A0 }

=A0 =A0 // Draw the component horizontally as normal, but to = an image/buffer rather than the GUI

=A0 =A0 if (orientation =3D VERTICAL) {
=A0 = =A0 =A0=A0 =A0// Rotate and possibly re-align the previously rendered image=
=A0 =A0 }

=A0 =A0 // Paint the image to= the GUI
}

On 11 September 2010 02:26= , Greg Brown <gkbro= wn@mac.com> wrote:
Good idea, but it wouldn't work. De= corators don't change the bounds of a component. They only augment its = appearance.

On Sep 10, 2010, at 3= :22 PM, Chris Bartlett wrote:


On 1= 0 September 2010 19:05, Greg Brown <gkbrown@mac.com> wrote:
I was actually thinking that a new= BoxPane.Divider class might be a better way to go. Separator has a "t= itle" property that would be hard to support in a vertical orientation= . Divider could simply mirror the orientation of the containing box pane.

Is it worth considering using some s= ort of rotation decorator that would rotate a horizontal Separator, includi= ng any title property +/- 90 degrees to create a vertical one?

Chris
=A0


--90e6ba6154e4f51435048fece45f--