87 TString ext = strrchr(pname,
'.');
91 pname =
gSystem->UnixPathName(pname);
131 static const TGPicture fEmptyPic {
"Empty" };
151 TString ext = strrchr(pname,
'.');
155 pname =
gSystem->UnixPathName(pname);
156 gSystem->ExpandPathName(pname);
193 img->
Scale(new_width, new_height);
216 gVirtualX->GetWindowSize(pxmap, xy, xy, w,
h);
249 while (isspace((
int)*ptr)) ++ptr;
252 while (isspace((
int)*ptr)) ++ptr;
317 Info(
"Print",
"no pictures in picture pool");
384 hashName.
Form(
"%s__%dx%d",
name, width, height);
385 return hashName.
Data();
const Mask_t kGCClipXOrigin
const Mask_t kPACloseness
Handle_t Pixmap_t
Pixmap handle.
Handle_t GContext_t
Graphics context handle.
const Mask_t kGCClipYOrigin
const Mask_t kPASize
width and height
Handle_t Window_t
Window handle.
ULongptr_t Handle_t
Generic resource handle.
int Int_t
Signed integer 4 bytes (int).
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int).
const char Option_t
Option string (const char).
void Printf(const char *fmt,...)
Formats a string in a circular formatting buffer and prints the string.
Encapsulate a graphics context used in the low level graphics.
void SetClipMask(Pixmap_t v)
Bitmap for clipping.
void SetAttributes(GCValues_t *values)
Set attributes as specified in the values structure.
TString fPath
icon search path
THashTable * fPicList
hash table containing the icons
TGPicturePool(const TGPicturePool &)
copy constructor
void Print(Option_t *option="") const override
List all pictures in the pool.
~TGPicturePool() override
Delete picture cache.
void FreePicture(const TGPicture *pic)
Remove picture from cache if nobody is using it anymore.
const TGClient * fClient
client for which we keep icon pool
const TGPicture * GetPictureOrEmpty(const char *name)
Like TGPicturePool::GetPicture() but, instead of returning null when the picture is not found,...
const TGPicture * GetPicture(const char *name)
Get a picture from the picture pool.
TGPicturePool & operator=(const TGPicturePool &)
assignment operator
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
Pixmap_t fPic
picture pixmap
PictureAttributes_t fAttributes
picture attributes
static const char * HashName(const char *name, Int_t width, Int_t height)
Static function returning a unique name used to look up a picture.
void Print(Option_t *option="") const override
Print picture info.
Pixmap_t fMask
picture mask pixmap
void Draw(Option_t *="") override
Default Draw method for all objects.
TGPicture(const char *name, Bool_t scaled=kFALSE)
~TGPicture() override
Delete picture object.
const char * GetName() const override
Returns name of object.
Pixmap_t GetPicture() const
Bool_t fScaled
kTRUE if picture is scaled
TString fName
name of picture
static TGGC & GetSelectedGC()
Return selection graphics context in use.
~TGSelectedPicture() override
Delete selected picture.
static TGGC * fgSelectedGC
TGSelectedPicture(const TGSelectedPicture &gp)
THashTable implements a hash table to store TObject's.
An abstract interface to image processing library.
static TImage * Open(const char *file, EImageFileTypes type=kUnknown)
Open a specified image file.
virtual void Scale(UInt_t, UInt_t)
virtual Pixmap_t GetPixmap()
virtual Pixmap_t GetMask()
TObject & operator=(const TObject &rhs) noexcept
TObject assignment operator.
TObject()
TObject constructor.
virtual void Info(const char *method, const char *msgfmt,...) const
Issue info message.
void SetRefCount(UInt_t r)
UInt_t References() const
void ToLower()
Change string to lower-case.
TSubString Strip(EStripType s=kTrailing, char c=' ') const
Return a substring of self stripped at beginning and/or end.
const char * Data() const
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
void CallRecursiveRemoveIfNeeded(TObject &obj)
call RecursiveRemove for obj if gROOT is valid and obj.TestBit(kMustCleanup) is true.
Graphics context structure.
Pixmap_t fClipMask
bitmap clipping; other calls for rects
Int_t fClipXOrigin
origin for clipping
Mask_t fMask
bit mask specifying which fields are valid
UInt_t fHeight
height of picture
Mask_t fMask
mask specifying which attributes are defined
Colormap_t fColormap
colormap to use
UInt_t fCloseness
allowable RGB deviation
UInt_t fWidth
width of picture