|
|
|
|
|
Re: Standalone Views Spacing [message #141454 is a reply to message #141444] |
Sat, 25 July 2009 11:13 |
Holger Staudacher Messages: 166 Registered: July 2009 |
Senior Member |
|
|
Hi Jordan,
great to hear you have found it out. I have never reduced the spacing,
so this is new to me, too. Thanks for the snippet, this will help a lot
to others.
Regards Holger
On 2009-07-24 21:27:01 +0200, jordan.bonnet@gmail.com (Jordan Bonnet) said:
> Hi Holger,
>
> I finally found it! In order to choose the spacing between Editors and
> Views, you have to overload AbstractPresentationFactory#getSashSize(int
> style). By default it is set to 3. (I had to enter into
> AbstractPresentationFactory with the debugger to realize that).
> A little snippet is always appreciated :
>
> public class MyPresentation extends PresentationFactory
> {
> // ... // Other implementations of abstract methods
> // that are not relevant for this example.
> // ...
>
> public int getSashSize(int style)
> {
> // Your choice of spacing between Editors and Views
> // By default it is set to 3.
> // I want my views to "touch" each other, so I am
> // returning 0.
>
> return 0;
> }
> }
>
>
> I hope it will save some time to someone !
>
> Regards,
> Jordan
>
>> Hi Jordan,
>> have you tried to change the bound in the ConfigurableStack#setBounds(
>> Rectangle ) method? Please take a look at our example implementation.
>> The ConfigurableStack implementation is in the bundle
>> org.eclipse.rap.design.example in the ViewStackPresentation class.
>
>> I think overiding createSash is not necessary.
>
>> Regards Holger
>
>
>
>> On 2009-07-20 02:25:20 +0200, jordan.bonnet@gmail.com (Jordan Bonnet) said:
>
>>> Thank you for your reply.
>>>
>>> Since I'm using RAP 1.2, I decided to go for the new API
>>> (interactiondesign). So I implemented a PresentationFactory and a
>>> ConfigurableStack (and it is working), but still I can't find where the
>>> spacing between two Standalone Views might be set for a given
>>> Perspective. There is a 3 pixels margin between my two views.
>>>
>>> Should I overload the PresentationFactory#createSash method ? Or is it
>>> somewhere else ?
>>>
>>> Thank you for your time.
>>>
>>> Jordan.
--
-----------------------------------------
http://eclipsesource.com
http://twitter.com/eclipsesource
|
|
|
Powered by
FUDForum. Page generated in 0.03572 seconds