1. wxEuphoria - set_tip()

How can I get the set_tip() to make a tip wider?

For example it says:

CUCUMBER,PEELED,RAW
338

I want it one line

CUCUMBER,PEELED,RAW 338

I have the \n after 338, not RAW.

new topic     » topic index » view message » categorize

2. Re: wxEuphoria - set_tip()

Jerry Story wrote:
> 
> How can I get the set_tip() to make a tip wider?
> 
> For example it says:
> 
> CUCUMBER,PEELED,RAW
> 338
> 
> I want it one line
> 
> CUCUMBER,PEELED,RAW 338
> 
> I have the \n after 338, not RAW.

I'm not aware of anything that will do that.

Matt

new topic     » goto parent     » topic index » view message » categorize

3. Re: wxEuphoria - set_tip()

Jerry:

    I don't use wxEuphoria but I know that it works in windows.
    In windows there is a TOOLINFO structure that contains a
    bounding rectangle entry that contains the size of the displayed
    text bounding box. Maybe Matt can tell you if there is a
    a similar thing in wxEuphoria.

Bernie

My files in archive:
WMOTOR, XMOTOR, W32ENGIN, MIXEDLIB, EU_ENGIN, WIN32ERU, WIN32API 

Can be downloaded here:
http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan

new topic     » goto parent     » topic index » view message » categorize

4. Re: wxEuphoria - set_tip()

Out of curiousity, what's the /n for, if it's at the end, and nowhere else?

I inserted that code of yours into a tooltip and everything seemed to come 
out fine. Could you post a sample here or mail me with the code?

new topic     » goto parent     » topic index » view message » categorize

5. Re: wxEuphoria - set_tip()

Jesse Adkins wrote:
> 
> Out of curiousity, what's the /n for, if it's at the end, and nowhere else?

Backslash, not forward slash. The \n means new line.

 
> I inserted that code of yours into a tooltip and everything seemed to come 
> out fine. Could you post a sample here or mail me with the code?

str = "PUMPKIN&SQUASH SD KRNLS,DRIED"
set_tip(widget,str)

It wraps after SD. I want it to not go to the next line until I tell to it to
with \n.

There seems to be some relation between the length of the first line (marked by
\n) and the width of the tip box, but only to a limit.

new topic     » goto parent     » topic index » view message » categorize

6. Re: wxEuphoria - set_tip()

Jerry Story wrote:
> 
> Jesse Adkins wrote:
> > 
> > Out of curiousity, what's the /n for, if it's at the end,
> > and nowhere else?
> 
> Backslash, not forward slash. The \n means new line.

The tips are multi-line.

I added "recipes" to DMAK (Diet Monger Ass Kicker). Click on a recipe name and a
tip lists the foods and quantities in the recipe. This requires multi-line. The
tip would would look better if it was wide enough for a food name and a number.
Some food names are long.

new topic     » goto parent     » topic index » view message » categorize

7. Re: wxEuphoria - set_tip()

I booted up Linux and did some more testing on it and the same thing happened.
I really don't know how to fix this problem. The routine has been wrapped 
properly and wxWidgets doesn't mention a tooltip problem in Linux.

It's probably Linux doing it for whatever reason. That's the only explanation
that I have.

new topic     » goto parent     » topic index » view message » categorize

8. Re: wxEuphoria - set_tip()

Jerry Story wrote:
> The tips are multi-line.
> 
> I added "recipes" to DMAK (Diet Monger Ass Kicker). Click on a recipe name and
> a tip lists the foods and quantities in the recipe. This requires multi-line.
> The tip would would look better if it was wide enough for a food name and a
> number. Some food names are long.

What I would suggest for you to do, instead of relying on the Tooltip, is to use
a Borderless Window, that will popup when clicked on a recipie, that way you have
full control over the size of the window, and how the text is printed on it. 
Then if the mouse moves, you can detect the movement, and move the popup with the
Mouse, till the user clicks someplace else.  This would be a more pallable option
that will work on both Windows and Linux, and wouldn't require having to mess
with the TOOLTIP Struct that wxWidgets doesn't give access to, since it is
different between Window Managers (Windows, KDE, Gnome, XFCE, and other various
WM).

Mario Steele
http://enchantedblade.trilake.net
Attaining World Dominiation, one byte at a time...

new topic     » goto parent     » topic index » view message » categorize

9. wxEuphoria - set_tip()

How can tooltips be turned off?

This is what happens.

set_tip(some_widget,"This is what the widget does.")

Good so far.
Now I want to turn it off.

set_tip(some_widget,"")  -- Nothing happens on a zero length string.

set_tip(some_widget," ") -- This makes a little yellow spot.

set_tip(some_widget,"\n") -- This makes a little yellow spot.

set_tip(some_widget,"\r") -- This makes a little yellow spot.

set_tip(some_widget,ESC) -- Error - unprintable char.
 
set_tip(some_widget,0) -- Error - type mismatch.

How can tooltips be turned off in wxEuphoria?

new topic     » goto parent     » topic index » view message » categorize

10. Re: wxEuphoria - set_tip()

Jerry Story wrote:
> 
> How can tooltips be turned off?

There is a [unwrapped] way to do this, using wxToolTip::Enable().  I'll
put it in the next version.

Matt

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu