mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 08:21:12 +02:00
cc_extra.h: allign method paintImage() and update comments
This commit is contained in:
@@ -101,7 +101,7 @@ bool paintTextBoxRel( const string& text,
|
||||
return box.isPainted();
|
||||
}
|
||||
|
||||
bool paintImage( const std::string& image_name,
|
||||
bool paintImage( const std::string& Image,
|
||||
const int& x,
|
||||
const int& y,
|
||||
const int& dx,
|
||||
@@ -114,7 +114,8 @@ bool paintImage( const std::string& image_name,
|
||||
int shadow_mode,
|
||||
const fb_pixel_t& color_shadow)
|
||||
{
|
||||
CComponentsPicture box( x, y, dx, dy, image_name, NULL, shadow_mode, color_frame, color_body, color_shadow, transparent);
|
||||
std::string image = (dx > 0 || dy > 0) ? CFrameBuffer::getInstance()->getIconPath(Image) : Image;
|
||||
CComponentsPicture box( x, y, dx, dy, image, NULL, shadow_mode, color_frame, color_body, color_shadow, transparent);
|
||||
box.doPaintBg(color_body !=0);
|
||||
box.setCorner(radius, corner_type);
|
||||
box.paint(CC_SAVE_SCREEN_NO);
|
||||
|
@@ -208,8 +208,10 @@ bool paintTextBoxRel( const std::string& text,
|
||||
int shadow_mode = CC_SHADOW_OFF,
|
||||
const fb_pixel_t& color_shadow = COL_SHADOW_PLUS_0);
|
||||
|
||||
/** Paint an image on screen.
|
||||
* @param[in] std::string& full path or filename
|
||||
/** Paints an image on screen with defined position. If no dimensions are defined, this method will try to paint an image as icon without any scale.\n
|
||||
* If an dimension is defined it will be try to scale the image.\n
|
||||
* Default behavior is paint an icon on screen like known method paintIcon() in class CFrameBuffer.
|
||||
* @param[in] std::string& full path to image file or icon filename without file extension (e.g. .png)
|
||||
* @param[in] x position
|
||||
* @param[in] y position
|
||||
* @param[in] dx witdh, default = 0 (no scale)
|
||||
@@ -261,7 +263,7 @@ bool paintTextBoxRel( const std::string& text,
|
||||
* @li driver/framebuffer.h
|
||||
* @li driver/colorgradient.h
|
||||
*/
|
||||
bool paintImage( const std::string& image_name,
|
||||
bool paintImage( const std::string& Image,
|
||||
const int& x,
|
||||
const int& y,
|
||||
const int& dx = 0,
|
||||
@@ -273,4 +275,5 @@ bool paintImage( const std::string& image_name,
|
||||
const fb_pixel_t& color_frame = COL_FRAME_PLUS_0,
|
||||
int shadow_mode = CC_SHADOW_OFF,
|
||||
const fb_pixel_t& color_shadow = COL_SHADOW_PLUS_0);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user