QFontAdapter Class Reference

QFont Adapter. More...

#include <QFontAdapter.h>

List of all members.

Static Public Member Functions

static void initialize (JNIEnv *env, jclass cls)
 Initializes QFontAdapter class.
static QFontAdaptertoQFont (JNIEnv *env, jobject font)
 Returns QFontAdapter instance.
static QFontAdaptertoQFont (jobject font)
 Returns QFontAdapter instance.
static jobject toJFont (JNIEnv *env, jclass fontClass, const QFont &font)
 Creates new QSwing font instance.
static jobject toJFont (const QFont &font)
 Creates new QSwing font instance.
static jlong newInstance (JNIEnv *env, jobject obj, jstring name, jint style, jint size)
 Returns new instance of QFontAdapter class.
static jlong newFontMetricsInstance (JNIEnv *env, jobject obj, jlong fontPonter)
 Returns new instance of QFontMetrics class.
static jstring getDefaultFontName (JNIEnv *env, jclass cls)
 Returns the name of default font.

Protected Member Functions

 QFontAdapter (jstring name, jint style, jint size)
 Constructs new QFontAdapter object.
 QFontAdapter (const QFont &font)
 Constructs new QFontAdapter object.


Detailed Description

QFont Adapter.

Author:
Slobodan Vrkacevic (slobodan.vrkacevic@gmail.com)
Version:
0.2.0

Constructor & Destructor Documentation

QFontAdapter::QFontAdapter ( jstring  name,
jint  style,
jint  size 
) [protected]

Constructs new QFontAdapter object.

Parameters:
name the font name
style the font style
size the font size

QFontAdapter::QFontAdapter ( const QFont &  font  )  [protected]

Constructs new QFontAdapter object.

Parameters:
font the font


Member Function Documentation

void QFontAdapter::initialize ( JNIEnv *  env,
jclass  cls 
) [static]

Initializes QFontAdapter class.

Parameters:
env the JNIEnv pointer
cls the QSwing font class
Exceptions:
FatalError if failed

QFontAdapter * QFontAdapter::toQFont ( JNIEnv *  env,
jobject  font 
) [static]

Returns QFontAdapter instance.

Parameters:
env the JNIEnv pointer
font the QSwing font object
Returns:
FontAdapter instance

QFontAdapter * QFontAdapter::toQFont ( jobject  font  )  [static]

Returns QFontAdapter instance.

Parameters:
font the QSwing font object
Returns:
FontAdapter instance

jobject QFontAdapter::toJFont ( JNIEnv *  env,
jclass  fontClass,
const QFont &  font 
) [static]

Creates new QSwing font instance.

Parameters:
env the JNIEnv pointer
fontClass the QSwing font class
font the QFont reference
Returns:
new QSwing font instance
Exceptions:
OutOfMemoryError java exception

jobject QFontAdapter::toJFont ( const QFont &  font  )  [static]

Creates new QSwing font instance.

Parameters:
font the QFont reference
Returns:
new QSwing font instance
Exceptions:
OutOfMemoryError java exception

jlong QFontAdapter::newInstance ( JNIEnv *  env,
jobject  obj,
jstring  name,
jint  style,
jint  size 
) [static]

Returns new instance of QFontAdapter class.

Parameters:
env the JNIEnv pointer
obj the QSwing font class
name the font name
style the font style
size the font size
Returns:
new instance of QFontAdapter class

jlong QFontAdapter::newFontMetricsInstance ( JNIEnv *  env,
jobject  obj,
jlong  fontPonter 
) [static]

Returns new instance of QFontMetrics class.

Parameters:
env the JNIEnv pointer
obj the QSwing font object
fontPonter the font pointer
Returns:
new instance of QFontMetrics class

jstring QFontAdapter::getDefaultFontName ( JNIEnv *  env,
jclass  cls 
) [static]

Returns the name of default font.

Parameters:
env the JNIEnv pointer
cls the QSwing font class
Returns:
the name of default font


Copyright © 2007 ETF and contributors. All Rights Reserved.