Merge branch 'master' into pu/mp

Conflicts:
	src/gui/epgplus.cpp


Origin commit data
------------------
Branch: ni/coolstream
Commit: 064f693bf7
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-04-08 (Sat, 08 Apr 2017)



------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2017-04-08 14:36:12 +02:00
19 changed files with 1060 additions and 1031 deletions

View File

@@ -730,6 +730,7 @@ fontsize.epg_date EPG Datum
fontsize.epg_info1 EPG Info 1
fontsize.epg_info2 EPG Info 2
fontsize.epg_title EPG Titel
fontsize.epgplus_item EPG-Plus Listeneintrag
fontsize.eventlist_datetime Datum/Zeit
fontsize.eventlist_event Event Info
fontsize.eventlist_itemlarge Groß

View File

@@ -730,6 +730,7 @@ fontsize.epg_date EPG Date
fontsize.epg_info1 EPG Info 1
fontsize.epg_info2 EPG Info 2
fontsize.epg_title EPG Title
fontsize.epgplus_item EPG-Plus item
fontsize.eventlist_datetime Date and time
fontsize.eventlist_event Event Info
fontsize.eventlist_itemlarge Large

View File

@@ -49,7 +49,7 @@ CCDraw::CCDraw() : COSDFader(g_settings.theme.menu_Content_alpha)
fr_thickness = fr_thickness_old = 0;
corner_type = corner_type_old = CORNER_ALL;
corner_type = corner_type_old = CORNER_NONE;
corner_rad = corner_rad_old = 0;
shadow = CC_SHADOW_OFF;
@@ -497,16 +497,6 @@ void CCDraw::paintFbItems(bool do_save_bg)
break;
}
dprintf(DEBUG_DEBUG, "[CCDraw]\n\t[%s - %d] firstPaint->save screen: %d, fbdata_type: %d\n\tx = %d\n\ty = %d\n\tdx = %d\n\tdy = %d\n",
__func__,
__LINE__,
firstPaint,
v_fbdata[i].fbdata_type,
v_fbdata[i].x,
v_fbdata[i].y,
v_fbdata[i].dx,
v_fbdata[i].dy);
/* Here we save the background of current box before paint.
* Only the reserved fbdata type CC_FBDATA_TYPE_BGSCREEN is here required and is used for this.
* This pixel buffer is required for the hide() method that will
@@ -524,20 +514,15 @@ void CCDraw::paintFbItems(bool do_save_bg)
for(size_t i=0; i< v_fbdata.size(); i++){
cc_fbdata_t& fbdata = v_fbdata[i];
// Don't paint on dimension or position error dx or dy are 0.
if (!CheckFbData(fbdata, __func__, __LINE__)){
continue;
}
int fbtype = fbdata.fbdata_type;
dprintf(DEBUG_DEBUG, "[CCDraw]\n\t[%s - %d], fbdata_[%d]\n\tx = %d\n\ty = %d\n\tdx = %d\n\tdy = %d\n",
__func__,
__LINE__,
(int)i,
fbdata.x,
fbdata.y,
fbdata.dx,
fbdata.dy);
//ignore bg screen layer
if (fbtype == CC_FBDATA_TYPE_BGSCREEN)
continue;
// Don't paint on dimension or position error dx or dy are 0.
if (!CheckFbData(fbdata, __func__, __LINE__))
continue;
/* Paint all fb relevant basic parts (shadow, frame and body)
* with all specified properties, paint_bg must be enabled.
@@ -548,12 +533,14 @@ void CCDraw::paintFbItems(bool do_save_bg)
frameBuffer->paintBoxFrame(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy, fbdata.frame_thickness, fbdata.color, fbdata.r, fbdata.rtype);
v_fbdata[i].is_painted = true;
}
continue;
}
}
if (paint_bg){
if (fbtype == CC_FBDATA_TYPE_BACKGROUND){
frameBuffer->paintBackgroundBoxRel(x, y, fbdata.dx, fbdata.dy);
frameBuffer->paintBackgroundBoxRel(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy);
v_fbdata[i].is_painted = true;
continue;
}
}
if (fbtype == CC_FBDATA_TYPE_SHADOW_BOX && ((!is_painted || !fbdata.is_painted)|| shadow_force || force_paint_bg)) {
@@ -575,6 +562,7 @@ void CCDraw::paintFbItems(bool do_save_bg)
fbdata.pixbuf = getScreen(fbdata.x, fbdata.y, fbdata.dx, fbdata.dy);
fbdata.is_painted = true;
}
continue;
}
}
if (paint_bg){

View File

@@ -72,8 +72,6 @@ class CComponentsButton : public CComponentsFrmChain, public CCTextScreen
///property: container for all assigned event message values, see driver/rcinput.h for possible values, default value = CRCInput::RC_nokey, see also setButtonDirectKey(), hasButtonDirectKey()
std::vector<neutrino_msg_t>cc_directKeys;
///property: assigned an alternate event message value, see driver/rcinput.h for possible values, default value = CRCInput::RC_nokey, see also setButtonDirectKeyAlt(), hasButtonDirectKeyAlt()
neutrino_msg_t cc_directKeyAlt;
///property: assigned return value, see also setButtonResult(), getButtonResult(), default value = -1 (not defined)
int cc_btn_result;
///property: assigned alias value, see also setButtonAlias(), getButtonAlias(), default value = -1 (not defined)

View File

@@ -87,6 +87,9 @@ CComponentsFrmClock::CComponentsFrmClock( const int& x_pos,
//set default text background behavior
cc_txt_save_screen = false;
//enable refresh of all segments on each interval as default
cl_force_repaint = true;
//set default running clock properties
cl_interval = interval_seconds;
cl_timer = NULL;
@@ -255,7 +258,7 @@ void CComponentsFrmClock::initCCLockItems()
//set size, text, color of current item
lbl->setDimensionsAll(x_tmp, y_tmp, w_tmp, h_tmp);
lbl->setColorAll(col_frame, col_body, col_shadow);
lbl->forceTextPaint(false);
lbl->forceTextPaint(cl_force_repaint);
lbl->setText(stmp, CTextBox::CENTER, cl_font, cl_col_text, cl_font_style);
//init background behavior of segment

View File

@@ -70,6 +70,9 @@ class CComponentsFrmClock : public CComponentsForm, public CCTextScreen
///text color
int cl_col_text;
///refresh mode
bool cl_force_repaint;
///current time format
std::string cl_format;
///primary time format
@@ -151,7 +154,7 @@ class CComponentsFrmClock : public CComponentsForm, public CCTextScreen
///returns true, if clock is running
virtual bool isRun() const {return cl_timer ? true : false;};
///set refresh interval in seconds, default value=1 (=1 sec)
virtual void setClockInterval(const int& seconds){cl_interval = seconds;};
virtual void setClockInterval(const int& seconds){cl_interval = seconds;}
///show clock on screen
virtual void paint(bool do_save_bg = CC_SAVE_SCREEN_YES);
@@ -163,6 +166,11 @@ class CComponentsFrmClock : public CComponentsForm, public CCTextScreen
///reinitialize clock contents
virtual void refresh() { initCCLockItems(); }
///enables force to repaint of all segments on each interval, Note: repaint of all segemts is default enabled.
void enableForceSegmentPaint(bool enable = true){cl_force_repaint = enable;}
///disables repaint of all segments on each interval, repaint happens only on changed segment value
void disableForceSegmentPaint(){enableForceSegmentPaint(false);}
/**Member to modify background behavior of embeded segment objects
* @param[in] mode
* @li bool, default = true

View File

@@ -63,11 +63,11 @@ void CComponentsFooter::initVarFooter( const int& x_pos, const int& y_pos, const
{
cc_item_type = CC_ITEMTYPE_FOOTER;
x = x_pos;
y = y_pos;
x = x_old = x_pos;
y = y_old = y_pos;
//init footer width
width = w == 0 ? frameBuffer->getScreenWidth(true) : w;
width = width_old = w == 0 ? frameBuffer->getScreenWidth(true) : w;
//init default fonts
initDefaultFonts();
@@ -77,15 +77,15 @@ void CComponentsFooter::initVarFooter( const int& x_pos, const int& y_pos, const
//init footer height
initCaptionFont();
height = max(h, cch_font->getHeight());
height = height_old = max(h, cch_font->getHeight());
shadow = shadow_mode;
ccf_enable_button_shadow = false ;
ccf_button_shadow_width = shadow ? OFFSET_SHADOW/2 : 0;
ccf_button_shadow_force_paint = false;
col_frame = color_frame;
col_body = color_body;
col_shadow = color_shadow;
col_frame = col_frame_old = color_frame;
col_body = col_body_old = color_body;
col_shadow = col_shadow_old = color_shadow;
cc_body_gradient_enable = cc_body_gradient_enable_old = CC_COLGRAD_OFF/*g_settings.theme.menu_ButtonBar_gradient*/; //TODO: not complete implemented at the moment
cc_body_gradient_direction = CFrameBuffer::gradientVertical;
cc_body_gradient_mode = CColorGradient::gradientDark2Light;
@@ -100,6 +100,9 @@ void CComponentsFooter::initVarFooter( const int& x_pos, const int& y_pos, const
addContextButton(buttons);
initCCItems();
initParent(parent);
//init repaint slot before re paint of body, if paint() is already done
initRepaintSlot();
}
void CComponentsFooter::setButtonLabels(const struct button_label_cc * const content, const size_t& label_count, const int& chain_width, const int& label_width)

View File

@@ -136,13 +136,17 @@ void CComponentsHeader::initVarHeader( const int& x_pos, const int& y_pos, const
cch_cl_sec_format = cch_cl_format;
cch_cl_enable_run = false;
//init slot before re paint of header, paint() is already done
sl_form_repaint = sigc::bind(sigc::mem_fun(*this, &CComponentsHeader::kill), col_body, -1, CC_FBDATA_TYPES, false);
OnBeforeRePaint.connect(sl_form_repaint);
addContextButton(buttons);
initCCItems();
initParent(parent);
//init repaint slot before re paint of body, if paint() is already done
initRepaintSlot();
}
void CComponentsHeader::initRepaintSlot(){
sl_form_repaint = sigc::bind(sigc::mem_fun(*this, &CComponentsHeader::kill), cc_parent ? col_body : 0, -1, CC_FBDATA_TYPES, false);
OnBeforeRePaint.connect(sl_form_repaint);
}
CComponentsHeader::~CComponentsHeader()

View File

@@ -112,6 +112,8 @@ class CComponentsHeader : public CComponentsForm, public CCTextScreen
void initButtons();
///sub: init clock object
void initClock();
///int repaint slot
void initRepaintSlot();
public:
enum

View File

@@ -89,11 +89,16 @@ void CComponentsItem::paintInit(bool do_save_bg)
//set current needed corner main box radius
int box_rad = corner_type ? corner_rad : 0;
//and ensure max main box radius < dimensions
if (2*box_rad > dy)
box_rad -= max(0, 2*box_rad-dy);
if (2*box_rad > dx)
box_rad -= max(0, 2*box_rad-dy);
//and ensure max main box radius < dimensions, avoids possible fb artefacts on screen
int box_rad2 = box_rad/2;
if(box_rad2 > dy || box_rad2 > dx){
int tmp_rad = box_rad;
if (box_rad2 > dx)
tmp_rad = (box_rad2-dx)*2;
if (box_rad2 > dy)
tmp_rad = (box_rad2-dy)*2;
box_rad = tmp_rad;
}
//Workaround: ensure radius values >= 0, framebuffer methode paintBoxRel() gets confused
box_rad = max(box_rad, 0);
@@ -113,13 +118,12 @@ void CComponentsItem::paintInit(bool do_save_bg)
int sh_cdy = box_rad+sw+th; //height
//adapt shadow corner dimensions if body dimensions are too small, use an offset if required
int /*sh_cdx_size_offset,*/ sh_cdy_size_offset = 0;
int /*sh_cdx_size_offset = 0,*/ sh_cdy_size_offset = 0;
if (sh_cdy*2 > dy)
sh_cdy_size_offset = sh_cdy*2-dy;
#if 0
if (sh_cdx*2 > dx)
sh_cdx_size_offset = sh_cdx*2-dx;
#endif
// if (sh_cdx*2 > dx)
// sh_cdx_size_offset = sh_cdx*2-dx;
//handle shadow positions
//...corner bottom right
int sh_cbr_x = ix+dx-sh_cdx+sw;

View File

@@ -74,6 +74,9 @@ CComponentsShapeCircle::CComponentsShapeCircle( int x_pos, int y_pos, int diam,
//CComponents
x = x_pos;
y = y_pos;
corner_type = corner_type_old = CORNER_ALL;
//width = height = d = diam;
shadow = shadow_mode;
shadow_w = OFFSET_SHADOW;

File diff suppressed because it is too large Load Diff

View File

@@ -3,14 +3,7 @@
Copyright (C) 2001 Steffen Hehn 'McClean'
Copyright (C) 2004 Martin Griep 'vivamiga'
Kommentar:
Diese GUI wurde von Grund auf neu programmiert und sollte nun vom
Aufbau und auch den Ausbaumoeglichkeiten gut aussehen. Neutrino basiert
auf der Client-Server Idee, diese GUI ist also von der direkten DBox-
Steuerung getrennt. Diese wird dann von Daemons uebernommen.
Copyright (C) 2017 Sven Hoefer
License: GPL
@@ -29,10 +22,10 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __epgplus__
#define __epgplus__
#ifndef __EPGPLUS_HPP__
#define __EPGPLUS_HPP__
#include <gui/components/cc.h>
#include "widget/menue.h"
#include <string>
@@ -47,46 +40,19 @@ class EpgPlus
{
//// types, inner classes
public:
enum FontSettingID
{
EPGPlus_header_font = 0,
EPGPlus_timeline_fonttime,
EPGPlus_timeline_fontdate,
EPGPlus_channelentry_font,
EPGPlus_channelevententry_font,
EPGPlus_footer_fontbouquetchannelname,
EPGPlus_footer_fonteventdescription,
EPGPlus_footer_fonteventshortdescription,
EPGPlus_footer_fontbuttons,
NumberOfFontSettings
};
enum SizeSettingID
{
EPGPlus_channelentry_width = 0,
EPGPlus_channelentry_separationlineheight,
EPGPlus_slider_width,
EPGPlus_horgap1_height,
EPGPlus_horgap2_height,
EPGPlus_vergap1_width,
EPGPlus_vergap2_width,
EPGPlus_separationline_thickness,
NumberOfSizeSettings
};
struct FontSetting
{
FontSettingID settingID;
const char* style;
int size;
};
struct SizeSetting
{
SizeSettingID settingID;
int size;
};
enum TViewMode
{
ViewMode_Stretch,
@@ -105,7 +71,10 @@ public:
{
//// construction / destruction
public:
Header ( CFrameBuffer* frameBuffer , int x , int y , int width);
Header(CFrameBuffer* frameBuffer,
int x,
int y,
int width);
~Header();
@@ -133,7 +102,12 @@ public:
{
//// construction / destruction
public:
TimeLine ( CFrameBuffer* frameBuffer , int x , int y , int width , int startX , int durationX);
TimeLine(CFrameBuffer* frameBuffer,
int x,
int y,
int width,
int startX,
int durationX);
~TimeLine();
@@ -160,9 +134,9 @@ public:
int x;
int y;
int width;
static int separationLineThickness;
static Font* fontTime;
static Font* fontDate;
static Font* font;
int startX;
int durationX;
@@ -172,15 +146,13 @@ public:
{
//// construction / destruction
public:
ChannelEventEntry
( const CChannelEvent* channelEvent
, CFrameBuffer* frameBuffer
, TimeLine* timeLine
, Footer* footer
, int x
, int y
, int width
);
ChannelEventEntry(const CChannelEvent* channelEvent,
CFrameBuffer* frameBuffer,
TimeLine* timeLine,
Footer* footer,
int x,
int y,
int width);
~ChannelEventEntry();
@@ -188,14 +160,9 @@ public:
public:
static void init();
bool isSelected
( time_t selectedTime
) const;
bool isSelected(time_t selectedTime) const;
void paint
( bool isSelected
, bool toggleColor
);
void paint(bool isSelected, bool toggleColor);
static int getUsedHeight();
@@ -210,7 +177,7 @@ public:
int x;
int y;
int width;
static int separationLineHeight;
static int separationLineThickness;
static Font* font;
};
@@ -221,16 +188,14 @@ public:
{
//// construction / destruction
public:
ChannelEntry
( const CZapitChannel* channel
, int index
, CFrameBuffer* frameBuffer
, Footer* footer
, CBouquetList* bouquetList
, int x
, int y
, int width
);
ChannelEntry(const CZapitChannel* channel,
int index,
CFrameBuffer* frameBuffer,
Footer* footer,
CBouquetList* bouquetList,
int x,
int y,
int width);
~ChannelEntry();
@@ -238,10 +203,7 @@ public:
public:
static void init();
void paint
( bool isSelected
, time_t selectedTime
);
void paint(bool isSelected, time_t selectedTime);
static int getUsedHeight();
@@ -258,11 +220,12 @@ public:
int x;
int y;
int width;
static int separationLineHeight;
static int separationLineThickness;
static Font* font;
TCChannelEventEntries channelEventEntries;
CComponentsDetailsLine *detailsLine;
};
typedef std::vector<ChannelEntry*> TChannelEntries;
@@ -271,13 +234,11 @@ public:
{
//// construction / destruction
public:
Footer
( CFrameBuffer* frameBuffer
, int x
, int y
, int width
, int height
);
Footer(CFrameBuffer* frameBuffer,
int x,
int y,
int width,
int height);
~Footer();
@@ -285,20 +246,11 @@ public:
public:
static void init();
void setBouquetChannelName
( const std::string& newBouquetName
, const std::string& newChannelName
);
void setBouquetChannelName(const std::string& newBouquetName, const std::string& newChannelName);
void paintEventDetails
( const std::string& description
, const std::string& shortDescription
);
void paintEventDetails(const std::string& description, const std::string& shortDescription);
void paintButtons
( button_label* buttonLabels
, int numberOfButtons
);
void paintButtons(button_label* buttonLabels, int numberOfButtons);
static int getUsedHeight();
@@ -309,20 +261,18 @@ public:
int x;
int y;
int width;
int buttonY;
int buttonHeight;
static Font* fontBouquetChannelName;
static Font* fontEventDescription;
static Font* fontEventShortDescription;
static Font* fontButtons;
static int color;
static Font* fontEventInfo1;
std::string currentBouquetName;
std::string currentChannelName;
};
class MenuTargetAddReminder : public CMenuTarget
{
public:
@@ -370,13 +320,12 @@ public:
virtual ~MenuOptionChooserSwitchSwapMode();
public:
int exec
( CMenuTarget* parent);
int exec(CMenuTarget* parent);
private:
EpgPlus* epgPlus;
int oldTimingMenuSettings;
TSwapMode oldSwapMode;
EpgPlus* epgPlus;
};
class MenuOptionChooserSwitchViewMode : public CMenuOptionChooser
@@ -424,10 +373,10 @@ public:
static int sizes[NumberOfSizeSettings];
*/
friend class EpgPlus::ChannelEventEntry;
friend class EpgPlus::ChannelEntry;
friend class EpgPlus::MenuOptionChooserSwitchSwapMode;
friend class EpgPlus::MenuOptionChooserSwitchViewMode;
friend class EpgPlus::ChannelEntry;
friend class EpgPlus::ChannelEventEntry;
//// construction / destruction
public:
@@ -476,6 +425,7 @@ private:
static time_t duration;
int entryHeight;
static int entryFontSize;
TViewMode currentViewMode;
TSwapMode currentSwapMode;
@@ -493,6 +443,8 @@ private:
int timeLineY;
int timeLineWidth;
int bodyHeight;
int channelsTableX;
int channelsTableY;
static int channelsTableWidth;
@@ -507,36 +459,11 @@ private:
int sliderY;
static int sliderWidth;
int sliderHeight;
static int sliderBackColor;
static int sliderKnobColor;
int footerX;
int footerY;
int footerWidth;
int horGap1X;
int horGap1Y;
int horGap1Width;
int horGap2X;
int horGap2Y;
int horGap2Width;
int verGap1X;
int verGap1Y;
int verGap1Height;
int verGap2X;
int verGap2Y;
int verGap2Height;
static int horGap1Height;
static int horGap2Height;
static int verGap1Width;
static int verGap2Width;
static int horGap1Color;
static int horGap2Color;
static int verGap1Color;
static int verGap2Color;
bool refreshAll;
bool refreshFooterButtons;
};
@@ -547,4 +474,4 @@ class CEPGplusHandler : public CMenuTarget
int exec(CMenuTarget* parent, const std::string &actionKey);
};
#endif
#endif // __epgplus__

View File

@@ -692,8 +692,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
if (doLoop)
{
if (!bigFonts && g_settings.bigFonts) {
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIGFONT_FACTOR));
}
bigFonts = g_settings.bigFonts;
start();
@@ -1075,8 +1075,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
} else
doRecord = false;
if (!bigFonts && g_settings.bigFonts) {
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIGFONT_FACTOR));
}
bigFonts = g_settings.bigFonts;
show(channel_id,epgData.eventID,&epgData.epg_times.startzeit,false);
@@ -1091,8 +1091,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
hide();
recDirs.exec(NULL,"");
if (!bigFonts && g_settings.bigFonts) {
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIGFONT_FACTOR));
}
bigFonts = g_settings.bigFonts;
show(channel_id,epgData.eventID,&epgData.epg_times.startzeit,false);
@@ -1234,8 +1234,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
loop = false;
else {
if (!bigFonts && g_settings.bigFonts) {
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIGFONT_FACTOR));
}
bigFonts = g_settings.bigFonts;
show(channel_id,tmp_eID,&tmp_sZeit,false);
@@ -1253,12 +1253,12 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
//printf("bigFonts %d\n", bigFonts);
if (bigFonts)
{
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() * BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() * BIGFONT_FACTOR));
} else
{
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() / BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() / BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() / BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() / BIGFONT_FACTOR));
}
g_settings.bigFonts = bigFonts;
if (mp_info)
@@ -1319,8 +1319,8 @@ void CEpgData::hide()
// 2004-09-10 rasc (bugfix, scale large font settings back to normal)
if (bigFonts) {
bigFonts = false;
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() / BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() / BIG_FONT_FAKTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO1]->getSize() / BIGFONT_FACTOR));
g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->setSize((int)(g_Font[SNeutrinoSettings::FONT_TYPE_EPG_INFO2]->getSize() / BIGFONT_FACTOR));
}
frameBuffer->paintBackgroundBoxRel(sx, sy, ox, oy);

View File

@@ -42,9 +42,6 @@
#include <vector>
#include <string>
#define BIG_FONT_FAKTOR 1.5
class CFrameBuffer;
class CEpgData
{

View File

@@ -139,7 +139,8 @@ const SNeutrinoSettings::FONT_TYPES epg_font_sizes[] =
SNeutrinoSettings::FONT_TYPE_EPG_TITLE,
SNeutrinoSettings::FONT_TYPE_EPG_INFO1,
SNeutrinoSettings::FONT_TYPE_EPG_INFO2,
SNeutrinoSettings::FONT_TYPE_EPG_DATE
SNeutrinoSettings::FONT_TYPE_EPG_DATE,
SNeutrinoSettings::FONT_TYPE_EPGPLUS_ITEM
};
size_t epg_font_items = sizeof(epg_font_sizes)/sizeof(epg_font_sizes[0]);
@@ -199,6 +200,7 @@ font_sizes_struct neutrino_font[SNeutrinoSettings::FONT_TYPE_COUNT] =
{LOCALE_FONTSIZE_EPG_INFO1 , 17, CNeutrinoFonts::FONT_STYLE_ITALIC , 2},
{LOCALE_FONTSIZE_EPG_INFO2 , 17, CNeutrinoFonts::FONT_STYLE_REGULAR, 2},
{LOCALE_FONTSIZE_EPG_DATE , 15, CNeutrinoFonts::FONT_STYLE_REGULAR, 2},
{LOCALE_FONTSIZE_EPGPLUS_ITEM , 18, CNeutrinoFonts::FONT_STYLE_REGULAR, 2},
{LOCALE_FONTSIZE_EVENTLIST_TITLE , 30, CNeutrinoFonts::FONT_STYLE_REGULAR, 0},
{LOCALE_FONTSIZE_EVENTLIST_ITEMLARGE, 20, CNeutrinoFonts::FONT_STYLE_BOLD , 1},
{LOCALE_FONTSIZE_EVENTLIST_ITEMSMALL, 14, CNeutrinoFonts::FONT_STYLE_REGULAR, 1},

View File

@@ -757,6 +757,7 @@ typedef enum
LOCALE_FONTSIZE_EPG_INFO1,
LOCALE_FONTSIZE_EPG_INFO2,
LOCALE_FONTSIZE_EPG_TITLE,
LOCALE_FONTSIZE_EPGPLUS_ITEM,
LOCALE_FONTSIZE_EVENTLIST_DATETIME,
LOCALE_FONTSIZE_EVENTLIST_EVENT,
LOCALE_FONTSIZE_EVENTLIST_ITEMLARGE,

View File

@@ -757,6 +757,7 @@ const char * locale_real_names[] =
"fontsize.epg_info1",
"fontsize.epg_info2",
"fontsize.epg_title",
"fontsize.epgplus_item",
"fontsize.eventlist_datetime",
"fontsize.eventlist_event",
"fontsize.eventlist_itemlarge",

View File

@@ -667,6 +667,7 @@ struct SNeutrinoSettings
FONT_TYPE_EPG_INFO1,
FONT_TYPE_EPG_INFO2,
FONT_TYPE_EPG_DATE,
FONT_TYPE_EPGPLUS_ITEM,
FONT_TYPE_EVENTLIST_TITLE,
FONT_TYPE_EVENTLIST_ITEMLARGE,
FONT_TYPE_EVENTLIST_ITEMSMALL,
@@ -925,6 +926,8 @@ const time_settings_struct_t timing_setting[SNeutrinoSettings::TIMING_SETTING_CO
#define DETAILSLINE_WIDTH 16 // TODO: scale2Res() ?
#define BIGFONT_FACTOR 1.5
struct SglobalInfo
{
hw_caps_t *hw_caps;