forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CALLBACK_REASON response ? in %gr callback

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+
View previous topic :: View next topic  
Author Message
acw



Joined: 04 Nov 2005
Posts: 148
Location: Darkest Devon

PostPosted: Mon May 08, 2017 3:39 pm    Post subject: CALLBACK_REASON response ? in %gr callback Reply with quote

I've been having quite a few problems moving over to FTN8.1 from 7.1. In this example I'm calling CLEARWIN_STRING@('CALLBACK_REASON') within a %gr callback and it is returning frequent "?" strings when clicking around within the area, particularly click and drag. It's not really a problem but the help states "?" means "not in callback", and this behaviour doesn't occur in 7.1.

Here's a cut-down example:
Code:

! Demonstrates occasional return of "?" from CLEARWIN_STRING@('CALLBACK_REASON') when
! within%gr callback. Typically on click and drag within the gr
winapp
use mswin

integer:: gr_dx = 600;
integer:: gr_dy = 300;

external grCallback

i = winio@('%ww[no_border,independent,not_fixed_size]&')
i = winio@('%ca[FTN Test]%nd&')
i = winio@('%pv%`^gr[white,user_resize,full_mouse_input,rgb_colours]%nl', &
           gr_dx, gr_dy, 1, grCallback)
end

integer function grCallback()
  use mswin
  character*32 rstr

  rstr = CLEARWIN_STRING@('CALLBACK_REASON')
  if (rstr /= 'MOUSE_MOVE' .and. rstr /= 'RESIZE') print *, rstr(1:LEN_TRIM(rstr))  ! sometimes "?" which means "not in callback"
  grCallback = 1
end function grCallback


This is compiling as x86 under Windows 10 so may well be a Win 10 issue, although it doesn't happen in Win 10 when compiled with FTN 7.1.

Alan
Back to top
View user's profile Send private message Visit poster's website
Kenneth_Smith



Joined: 18 May 2012
Posts: 79
Location: Glasgow, Scotland.

PostPosted: Mon May 08, 2017 9:27 pm    Post subject: Reply with quote

Alan,
I don't know the answer to this, but I can replicate your issue in Windows 10. Seems to me that a left click is fine, a right click is fine too, but a simultaneous left and right click, i.e. finger trouble/big thumb on my keyboard touch mouse produces "?".

Ken
Back to top
View user's profile Send private message Visit poster's website
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 4776
Location: Salford, UK

PostPosted: Tue May 09, 2017 7:04 am    Post subject: Reply with quote

I have made a note to revisit this issue to see if anything can be done.
Back to top
View user's profile Send private message
LitusSaxonicum



Joined: 23 Aug 2005
Posts: 1599
Location: Yateley, Hants, UK

PostPosted: Tue May 09, 2017 2:16 pm    Post subject: Reply with quote

Paul's use of the word 'revisit' indicates that this topic has been on the Forum before. The issue is the huge number of mouse interrupts when you use full_mouse_input. One of the best suggestions was to interrogate the mouse position and button states, and if nothing changed since the last interrupt, throw it away.

Eddie
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+ All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group