Issue 21614 - spin buttons: allow for horizontal orientation
Summary: spin buttons: allow for horizontal orientation
Status: CLOSED FIXED
Alias: None
Product: gsl
Classification: Code
Component: code (show other issues)
Version: OOo 1.1 RC5
Hardware: All All
: P3 Trivial (vote)
Target Milestone: OOo 2.0
Assignee: Frank Schönheit
QA Contact: issues@gsl
URL:
Keywords:
Depends on:
Blocks: 21605
  Show dependency tree
 
Reported: 2003-10-23 13:42 UTC by Frank Schönheit
Modified: 2004-12-30 08:32 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
suggested patch (8.74 KB, patch)
2003-10-29 07:46 UTC, Frank Schönheit
no flags Details | Diff
suggested patch (now really) (9.74 KB, patch)
2003-10-29 08:06 UTC, Frank Schönheit
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description Frank Schönheit 2003-10-23 13:42:59 UTC
In the course of issue 21605, we will offer the possibility to include spin
button form controls into documents.

There already is a VCL control which implements a spin button (SpinButton,
spin.hxx/spinbtn.cxx), but it currently lacks a feature which is needed for the
new control: It must be able to have a horizontal orientation, instead of always
being vertically oriented.
Comment 1 stephan_schaefer 2003-10-24 12:43:10 UTC
accepted
Comment 2 Frank Schönheit 2003-10-29 07:46:20 UTC
Created attachment 10737 [details]
suggested patch
Comment 3 Frank Schönheit 2003-10-29 08:05:37 UTC
fs->ssa: I noticed that some code for horizontal orientation is
already there, despite what I originally said. So I could not resist
tampering with this myself :).

The attached patch does a number of things:

- it introduces value handling for the spin button. This is completely
independent on this bug here, I planned to introduce this, anyway. I
think it can go into this base class (instead of deriving), at least
because this class is nowhere used at the moment.

- the spin button doesn't use hard-coded repeat delays anymore, but
uses the MouseSettings, like it is done in scroll bars and push
buttons, too. This is also independent on this bug, and was planned,
anyway. For the same reason as above (nobody used this class so far),
I consider this no harm.

- The spin button now reacts on changes in the WB_HSCROLL and
WB_REPEAT style, adjusing it's look/behaviour. Formerly, they were
evaluated in the ctor only, and thus could not be changed afterwards.

- it introduces a new boolean parameter bMirrorHorz at
ImplDrawSpinButton. This was necessary since when drawing
horizontally, the routine associated "up" with "left" and "down" with
"right". This is surely not expectation conformant for a horizontal
spin button, which should be similar to e.g. scroll bars. However,
since the behaviour was used for (vertical) tool boxes, it cannot
simply be changed, thus the extra parameter, which now is used by the
SpinButton.
Again, this should not have negative impact, since this function is
used inside VCL only, according to
http://ooo.ximian.com/lxr/ident?i=ImplDrawSpinButton.
Comment 4 Frank Schönheit 2003-10-29 08:06:26 UTC
Created attachment 10738 [details]
suggested patch (now really)
Comment 5 Frank Schönheit 2003-10-29 08:07:33 UTC
Stephan, do you mind reviewing the patch? If it finds your mercy, I
would grab this issue and check in the changes into my CWS.
Comment 6 Frank Schönheit 2003-10-29 11:46:26 UTC
grabbing the issue (after a off-line approval)
Comment 7 Frank Schönheit 2003-10-29 11:47:29 UTC
fixed in CWS frmcontrols01.
SSA brought up the question about the accessibility of this new
control - this will be clarified separately
Comment 8 Frank Schönheit 2003-12-02 12:11:56 UTC
verified in final CWS build
Comment 9 Frank Schönheit 2004-12-30 08:32:47 UTC
fix verified in 680 m66