Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Example of IMBeep()

Status
Not open for further replies.

sus98

Programmer
Jan 17, 2003
4
0
0
IN
Hi all,
I came to know that there is a function called IMBeep() present in the AIX Unix, helps to produce beep in application program...

But i could not find how to set the third parameter of the IMBeep().

Please give a small set or an example, how i can use that function.

with warm Regards
sus98
 
Here are a few help pages I have at my disposal.
Your third param comes - apparently from the IMCreate routine. I've included this page also.

IMBeep Callback Subroutine
Purpose
Tells the application program to emit a beep sound.

Syntax
int IMBeep(IM, Percent, UData)
IMObject IM;
int Percent;
caddr_t UData;
Description
The IMBeep subroutine tells the application program to emit a beep sound.

Parameters
IM Indicates the input method instance.
Percent Specifies the beep level. The value range is from -100 to 100, inclusively. A -100 value means no beep.
UData An argument passed by the IMCreate subroutine.

Return Values
If an error occurs, the IMBeep subroutine returns the IMError global variable. Otherwise, the IMNoError value is returned.

Implementation Specifics
This subroutine is provided by applications that use input methods.

Related Information
The IMCreate subroutine.

IMCreate Subroutine
Purpose
Creates one instance of an IMObject object for a particular input method.

Library
Input Method Library (libIM.a)

Syntax
IMObject IMCreate(IMfep, IMCallback, UData)
IMFep IMfep;
IMCallback *IMCallback;
caddr_t UData;
Description
The IMCreate subroutine creates one instance of a particular input method. Several input method instances can be created under one input method.

Parameters
IMfep Specifies the input method.
IMCallback Specifies a pointer to the caller-supplied IMCallback structure.
UData Optionally specifies an application's own information to the callback functions. With this information, the application can avoid external references from the callback functions. The input method does not change this parameter, but merely passes it to the callback functions. The UData parameter is usually a pointer to the application data structure, which contains the information about location, font ID, and so forth.

Return Values
The IMCreate subroutine returns a pointer to the created input method instance of type IMObject. If the subroutine is unsuccessful, a null value is returned and the imerrno global variable is set to indicate the error.

Hope this helps.
mssngr.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top