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 

api functions don't work

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



Joined: 16 Oct 2009
Posts: 58
Location: München

PostPosted: Thu Sep 02, 2010 5:43 pm    Post subject: api functions don't work Reply with quote

Paul,
why don't work the api functions, i need the arc function, what is wrong?

The clearwin polyline function works fine.
I want to choose a printer at every start.


Thank you

[/code]

winapp 0,0
program prtest
include<windows.ins>

integer*4 width,height,xi(2),yi(2),n,m
integer*4 kp,jp,icol
integer*4 hnd1
logical*4 done

data hnd1/1/
data kp,jp/0,0/

kp=open_printer@(hnd1)
jp=select_graphics_object@(hnd1)
call GET_GRAPHICAL_RESOLUTION@( WIDTH, HEIGHT )
icol = rgb@(255,0,0)

xi(1) = 500
yi(1) = 500
xi(2) = 2000
yi(2) = 2000
n = 2
call draw_polyline@(xi,yi,n,icol) ! clearwin

! m = moveto(hnd1,1000,2000) ! api don't work
! done = lineto(hnd1,1000,2000) ! api don't work
done = arc(hnd1,100,100,500,500,300,100,300,500) ! api don't work
done = ellipse(hnd1,100,100,500,500) ! api don't work

kp=close_printer@(hnd1)
stop
end
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


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

PostPosted: Thu Sep 02, 2010 9:01 pm    Post subject: Reply with quote

The first argument of MoveTo etc is a handle to the relevant device context.
clearwin_info@('GRAPHICS_HDC') should provide this value.
Back to top
View user's profile Send private message AIM Address
Bartl



Joined: 16 Oct 2009
Posts: 58
Location: München

PostPosted: Fri Sep 03, 2010 7:10 am    Post subject: Reply with quote

Thank you very much for the solution and the excellent forum,
it works fine.

Bartl
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