Bug 414569 - [ToolTip] Support SWT.BALLOON style
Summary: [ToolTip] Support SWT.BALLOON style
Status: ASSIGNED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 2.2   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 414570
  Show dependency tree
 
Reported: 2013-08-07 07:29 EDT by Tim Buschtoens CLA
Modified: 2013-09-23 05:42 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Buschtoens CLA 2013-08-07 07:29:39 EDT
A ToolTip created with the BALLOON style flag will add a "tail" pointer to it to make it look like a speech balloon. RAP does not support this. It should also be possible to add such tails to shells and composites, and also normal tooltips, pointing either inwards our outwards.

Since the tail/pointer has to match the border and background of the widget, it has to be themeable. There also needs a way to control it's relative position, either by theming or java API.
Comment 1 Tim Buschtoens CLA 2013-08-07 07:39:28 EDT
Theming could control the position using the combination of 
left/top/right/bottom  properties, at least two of which have always to be set to "auto".
They 

E.g. for a tail at the bottom of the widget, 10px from the left.
background-image: tail.png
left: 10px;
bottom: 0px;
right: auto;
top: auto;

At the left, assuming the image is 5x5pixel
left: -5px;
top: 10px;
bottom: auto;
right: auto;

At the right, pointing inwards:
right: 0px;
top: 10px;
bottom: auto;
right: auto;

"auto" could also be used for auto-centering:
top: auto;
bottom: -5px;
right: auto;
left: auto;
Comment 2 Tim Buschtoens CLA 2013-09-23 05:42:19 EDT
Normal tooltips now support "pointer"/"tail" (Bug 414570), but their placement is automatic. This is not possible here since the tooltip widget doesn't "know" where to point to.