How To: Graphics on buttons?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How To: Graphics on buttons?

bh77a-2
I am trying to create graphical buttons and am having mixed results.  
Here is a sample of the code that I am trying...

id_1=ui.openres(Tbmp,1000)
btn_1=ui.pbutton("",1,1000)
ui.closeres(1000)

The button will display with a bitmap (Tbmp 1000 embedded into the
compiled PRC using BIRD) on it, but while the actual bitmap in the
compiled PRC is small (20x20 @ 144), the button displays as about 75x75
@ 144 with the small graphic centered in it.

I have tried variations of the above code and none seem to work.  Any
thoughts as to what I might be doing wrong?

Plua 2.0b4
Palm TX / Palm Tungsten E



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/plua/

<*> To unsubscribe from this group, send an email to:
    [hidden email]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply | Threaded
Open this post in threaded view
|

Re: How To: Graphics on buttons?

bh77a-2
In case anyone stumbles across this issue, the solution is to create
the Tbmp resources with a resolution of 72 dpi.  Plua seems to require
that they be single density or low resolution for proper handling on
buttons and other ui elements.

On Mar 18, 2006, at 12:28 AM, Brian Houghton wrote:

> I am trying to create graphical buttons and am having mixed results.
> Here is a sample of the code that I am trying...
>
> id_1=ui.openres(Tbmp,1000)
> btn_1=ui.pbutton("",1,1000)
> ui.closeres(1000)
>
> The button will display with a bitmap (Tbmp 1000 embedded into the
> compiled PRC using BIRD) on it, but while the actual bitmap in the
> compiled PRC is small (20x20 @ 144), the button displays as about 75x75
> @ 144 with the small graphic centered in it.
>
> I have tried variations of the above code and none seem to work.  Any
> thoughts as to what I might be doing wrong?
>
> Plua 2.0b4
> Palm TX / Palm Tungsten E
>
>
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
>
>



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/plua/

<*> To unsubscribe from this group, send an email to:
    [hidden email]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/