- Main Page
- Classes
- Directories
- Related Pages

- Class List
- Class Hierarchy
- Class Members

# TkPhoto Class Reference

Photo represent loaded image in shell. More...

`#include <tk_photo.h>`

Inheritance diagram for TkPhoto:

List of all members.

## Public Member Functions

const char * | getType () const
| Return type of class.
| TkPhoto (Ptr< TclInterp > &interp, const char *fileName)
const string & | toString () const
| Simple text dump.
void | getSize (int *width, int *height) const
void | setSize (int width, int height)

## Detailed Description

Photo represent loaded image in shell.

Date:
  01-12-2006

Author:
  Ondrej Svejdar

Todo:
  Photo can be as well accessed like widget. See if it can be inherited from TkBase.

Bug:

## Constructor & Destructor Documentation

TkPhoto::TkPhoto | ( | Ptr< TclInterp > & | interp,
|  | const char * | fileName
| ) | `[inline]`

| ctor NOTE: Not all image types are supported. You can even register your own image type handler. Base Tk distribution comes with PPM/PGM and GIF formats. Loading unsuported image type would lead to blank image. For details see description of "photo" command in the Tk manual pages.

Parameters:

  | interp | interpret
  | fileName | name of file with image

Returns:

## Member Function Documentation

void TkPhoto::getSize | ( | int * | width,
|  | int * | height
| ) | const`[inline]`

| Return size of image

Parameters:

  | width | image width
  | height | image height

const char* TkPhoto::getType | ( |  | ) | const`[inline, virtual]`

| Return type of class.

Returns:
  type of class

Reimplemented from TXmlObject.

void TkPhoto::setSize | ( | int | width,
|  | int | height
| ) | `[inline]`

| Resize image to desired size

Parameters:

  | width | width
  | height | height

const string& TkPhoto::toString | ( |  | ) | const`[inline, virtual]`

| Simple text dump.

Returns:
  if not overriden, it returns type of class

Reimplemented from TObject.

The documentation for this class was generated from the following files:

- H:/projs/dotNET/eda/src/tk/gui/image/tk_photo.h
- H:/projs/dotNET/eda/src/tk/gui/image/tk_photo.cpp