AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

SOLVED: Tablet Input Panel show/hide

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Tue Jan 06, 2009 2:52 am    Post subject: SOLVED: Tablet Input Panel show/hide Reply with quote

Hi All,

I've got something you guys can probably help me with. I have a tablet PC, and want to use the 4th and 5th button of my mouse to show and hide the Tablet Input Panel (TIP). The showing is easy, but hiding doesn't seem to work. I've been juggling with it for some time now, but can't seem to find the solution.

Xbutton2::
Run TabTip.exe
return

(this works, and shows the window).

However the hiding seems to be more of a problem. The TIP window doesn't have a name, so I cannot use that. I used window spy and this ( http://www.autohotkey.com/forum/viewtopic.php?t=8366 ) thread to find the class name for tap tip, which is IPTip_Main_Window. But still, I can't figure it out.

There is a button on the taskbar which identifies as TIPBand, and pressing that toggles show/hide of the main Input window. I think it refers to tipband.dll. I don't know much about programming, but hopefully someone can figure it out!

Thanks,

Billy


Last edited by Bllly on Tue Feb 10, 2009 8:30 am; edited 1 time in total
Back to top
View user's profile Send private message
evan
Guest





PostPosted: Tue Jan 06, 2009 6:51 am    Post subject: Reply with quote

as stated in help file:
Quote:
Run, Target [, WorkingDir, Max|Min|Hide|UseErrorLevel, OutputVarPID]

u can output the PID, so winhide, winclose can work with the ahk_pid %OutputVarPID%
Back to top
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Tue Jan 06, 2009 7:33 am    Post subject: Reply with quote

Thanks for your reply.

I didn't quite get it yet.
The program's unique Process ID (PID) is blank, so that cannot be used.
Any other ideas?

Billy
Back to top
View user's profile Send private message
n-l-i-d
Guest





PostPosted: Wed Jan 07, 2009 2:53 am    Post subject: Reply with quote

Code:
;DetectHiddenWindows, On

XButton2::
IfWinNotExist, ahk_class IPTip_Main_Window
   Run, TabTip.exe
Else
   WinShow, ahk_class IPTip_Main_Window
Return

XButton3::
   WinHide, ahk_class IPTip_Main_Window
Return


Question
Back to top
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Thu Jan 08, 2009 8:28 am    Post subject: Reply with quote

That also doesn't work . I tried with process, close ... but to no luck. Any more suggestions?
Back to top
View user's profile Send private message
Talisman2



Joined: 27 Nov 2008
Posts: 16
Location: Johannesburg, South Africa

PostPosted: Mon Jan 12, 2009 8:03 pm    Post subject: Reply with quote

I also couldn't identify the TABTIP.exe application while running, and trying to winkill the pid does not work - UNLESS you run your AHK process as Administrator - but killing the USER tabtip.exe process makes TABTIP rather unstable.

So... and this is a REALLY sucky way to do this, but it works... :-/

Code:

XButton1::
CoordMode, Mouse, Screen ; Set us to screen co-ord mode
MouseGetPos, nX, nY ; Get the current mouse co-ords
SysGet, Mon1, Monitor ; Get the screen resolution
MouseClick, Left, Mon1Right - 47, 8 ; Click the X button for the TIP
MouseMove, nX, nY ; Restore the mouse to it's original co-ords
return


I've simply left-clicked the X button of the TIP (47 means that you shouldn't click the X button of another window by pressing XButton1 more than 1 time by mistake), and 8 is approximately in the middle of the X button height.
Like I said, it's not elegant, but it works...

Naturally, if your TABTIP is docked at the bottom of your screen, you need to modify the X co-ord ( 8 ) to some valid co-ordinate.
If your tabtip is a floating window, well... work it out...
_________________
Keep it Real
Talismaniac
http://www.autohotkey.net/~Talisman
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Tue Jan 13, 2009 3:48 am    Post subject: Reply with quote

Thanks for you help, will post findings ASAP.
Back to top
View user's profile Send private message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Fri Jan 16, 2009 5:20 am    Post subject: Reply with quote

hey,

I tried it out and it obviously works! Thanks Talis. The solution is quite ugly though, so if some one has some other ideas/options it would be great!

Bllly
Back to top
View user's profile Send private message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Mon Jan 19, 2009 5:16 am    Post subject: Reply with quote

Okay, the solution works, but is not optimal. Is there any way to take into account where the window is floating? Sometimes I accidentally move the TIP window, and then the script obviously doesn't work anymore...

Thanks,
Billy
Back to top
View user's profile Send private message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Thu Jan 29, 2009 5:19 am    Post subject: Reply with quote

Hey,

Does anybody has another solution? Especially the method doesn't work so good when I am moving the TIP around. AutoHotKey is a very powerful program, I'm sure there must be a better solution!

Who can help?
Billy
Back to top
View user's profile Send private message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Tue Feb 03, 2009 12:51 am    Post subject: Reply with quote

Bump... Crying or Very sad
Back to top
View user's profile Send private message
Bllly



Joined: 06 Jan 2009
Posts: 9

PostPosted: Tue Feb 10, 2009 8:29 am    Post subject: yeah! Reply with quote

I spend roughly half the day on the IRC channel, and the guys there figured it out. Thanks!

Solution:

Code:
XButton1::
PostMessage,0x112,0xF060,,,ahk_class IPTip_Main_Window
return
Back to top
View user's profile Send private message
drmurdoch



Joined: 10 Nov 2006
Posts: 110

PostPosted: Tue Feb 10, 2009 10:13 am    Post subject: Reply with quote

Cool solution.
Back to top
View user's profile Send private message
hummer



Joined: 19 Aug 2010
Posts: 1

PostPosted: Wed Dec 07, 2011 9:29 am    Post subject: Reply with quote

Shocked that is 'hide' code.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group