1. RE: Alt+Tab icon in windows

jaspers_post at hotmail.com wrote:
> Hi everyone,
> 
> I've got an exe-file (made with bindw) with my own icon. This works 
> fine. The installer I use recognises this icon for example. However when 
> 
> I use Alt+Tab in windows to switch between programs Euphoria's standard 
> icon is shown instead of my own. Has anayone else encountered this 
> problem and does anyone has a solution?

Jasper:

   The problem maybe because your icon only contains a 32x32
   icon. A real windows icon should contain a 16x16, 32x32
   and 48x48. This icon can also contain these 3 icons in
   in different pallete sizes. When windows displays an icon
   it selects the appropriate icon to display or tries to
   adjust the icon to fit the use. What maybe happening is that
   the bindw is only replacing the 32x32 icon and when windows
   selects the icon it uses one of the sizes that was not
   replaced ( the euphoria icon ). The way you can find out
   is to select an icon from some other windows program that
   you know works and try bindw-ing it to your program.
   
   Out on the web and you will find icon editors that will
   allow you to create icons that contain more than one size
   if this is your program. 

Bernie

new topic     » topic index » view message » categorize

2. RE: Alt+Tab icon in windows

Jasper,

Using Win32Lib and my own icon when binding, I put the following in my 
'onOpen' routine.

atom hicon, exw
  exw = allocate_string("exw")
  hicon = w32Func( xLoadIcon, {instance(), exw} )
  free(exw)
  if sendMessage( CardWin, WM_SETICON, 1, hicon ) then end if

This puts my bound icon in my window, and shows it when I ALT-TAB.  

-- Brian

jaspers_post at hotmail.com wrote:
> Hi everyone,
> 
> I've got an exe-file (made with bindw) with my own icon. This works 
> fine. The installer I use recognises this icon for example. However when 
> 
> I use Alt+Tab in windows to switch between programs Euphoria's standard 
> icon is shown instead of my own. Has anayone else encountered this 
> problem and does anyone has a solution?
> 
> Bye,
> 
> Jasper. 
> 
>

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

3. RE: Alt+Tab icon in windows

I don't know if you are using Win32Lib or not but I just sent Derek a 
fix that would handle bound icons automatically in the library (and also 
a 'setIcon()' bugfix).  Maybe the code will make it into the next 
release...

-- Brian


Brian Broker wrote:
> Jasper,
> 
> Using Win32Lib and my own icon when binding, I put the following in my 
> 'onOpen' routine.
> 
> atom hicon, exw
>   exw = allocate_string("exw")
>   hicon = w32Func( xLoadIcon, {instance(), exw} )
>   free(exw)
>   if sendMessage( CardWin, WM_SETICON, 1, hicon ) then end if
> 
> This puts my bound icon in my window, and shows it when I ALT-TAB.  
> 
> -- Brian
> 
> jaspers_post at hotmail.com wrote:
> > Hi everyone,
> > 
> > I've got an exe-file (made with bindw) with my own icon. This works 
> > fine. The installer I use recognises this icon for example. However when 
> > 
> > 
> > I use Alt+Tab in windows to switch between programs Euphoria's standard 
> > icon is shown instead of my own. Has anayone else encountered this 
> > problem and does anyone has a solution?
> > 
> > Bye,
> > 
> > Jasper. 
> > 
> >

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

4. RE: Alt+Tab icon in windows

snip -- a 'setIcon()' bugfix) -- snip Brian

Everybody thanks for the advice. I haven't had time yet to test the 
proposed solutions, I hope this evening. I indeed use Win32Lib so the 
fix will come in handy. But what's the 'setIcon()' bug Brian refered to?

Bye,

Jasper.

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

5. RE: Alt+Tab icon in windows

I think Derek is on vacation at the moment so I haven't received any 
feedback from him about it.  Procedure setIcon takes 2 arguments.  
According to the docs for the 2nd parameter:
If icon is a sequence, it will be assumed to be the name of an icon 
file, and Win32Lib will attempt to load the icon. 
Otherwise, icon is assumed to be the handle of an icon.

However, if the icon is not a sequence, the library attempts to use 
'xLoadIcon' to get a handle:

handle = w32Func(xLoadIcon, {NULL, icon})

However, if 'icon' is already a handle, then the code should simply be:

handle = icon

-- Brian


 


Jasper wrote:
> snip -- a 'setIcon()' bugfix) -- snip Brian
> 
> Everybody thanks for the advice. I haven't had time yet to test the 
> proposed solutions, I hope this evening. I indeed use Win32Lib so the 
> fix will come in handy. But what's the 'setIcon()' bug Brian refered to?
> 
> Bye,
> 
> Jasper. 
> 
>

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

Search



Quick Links

User menu

Not signed in.

Misc Menu