Solved

define click point custom cursor

Posted on 2001-06-21
5
285 Views
Last Modified: 2010-04-06
hi,
i've made a custom cursor for my delphi program. The cursor looks like a paintbox. The default windows cursor (arrow) has its effective pixel in the upperleft corner (the point of the arrow). My own cursor has the 'effective pixel' also there. is there anyway to change this cuz i'd like to make the right side of custom cursor to be 'effective'

thanks in advance.

p.s. i know this is a little weird story, but i dont know another way to ask....
0
Comment
Question by:brutebass
5 Comments
 
LVL 13

Expert Comment

by:Epsylon
ID: 6213710
Take a look at the 'CreateCursor' and 'SetCursor' API functions.
0
 
LVL 27

Accepted Solution

by:
kretzschmar earned 100 total points
ID: 6213782
normally you can define this point with the tool you've used to design it, like in microangelo or (not sure) in the workshop, which comes with delphi
0
 
LVL 2

Expert Comment

by:FrodoBeggins
ID: 6213941
Yes, in the tool you are using look for "define hotspot"
0
 
LVL 2

Expert Comment

by:FrodoBeggins
ID: 6213971
Or you can change it directly in the .cur file. The file fomat is (in C):
typedef struct _CURSORDIR {
  WORD           cdReserved;
  WORD           cdType;
  WORD           cdCount;
  CURSORDIRENTRY cdEntries[];
} CURSORDIR;

typedef struct _CURSORDIRENTRY {
  BYTE           bWidth;
  BYTE           bHeight;
  BYTE           bColorCount;
  BYTE           bReserved;
  WORD           wXHotspot;
  WORD           wYHotspot;
  DWORD          lBytesInRes;
  DWORD          dwImageOffset;
} CURSORDIRENTRY;

So you are on the 6-th and 7-th word, if I'm not wrong...
0
 

Author Comment

by:brutebass
ID: 6214024
great, didnt see the button in microangelo, but that was because i didnt look for it :)

thanks...all  of you
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Concerto provides fully managed cloud services and the expertise to provide an easy and reliable route to the cloud. Our best-in-class solutions help you address the toughest IT challenges, find new efficiencies and deliver the best application expe…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now