Set the a default pixel threshold in CRL/etc/commons.display.

NOTE: Due to Python pathes, the NDA.common is *not* seen, even by NDA
      protected configuration. They are using the non-NDA one. No harm
      in that, just need to be known...
This commit is contained in:
Jean-Paul Chaput 2021-11-26 11:32:33 +01:00
parent 7c0f1fcf58
commit 6a3c9d1d54
2 changed files with 6 additions and 0 deletions

View File

@ -13,12 +13,17 @@
# +-----------------------------------------------------------------+
import Cfg
import Viewer
from helpers import overlay, l, u, n
from common.colors import toRGB
from common.patterns import toHexa
def createStyles ( scale=1.0 ):
with overlay.CfgCache(priority=Cfg.Parameter.Priority.UserFile) as cfg:
cfg.viewer.minimumSize = 500
cfg.viewer.pixelThreshold = 5
# ----------------------------------------------------------------------
# Style: Alliance.Coriolis [black].

View File

@ -1112,6 +1112,7 @@ namespace Hurricane {
, _textFontHeight (20)
, _pixelThreshold (Cfg::getParamInt("viewer.pixelThreshold",50)->asInt())
{
//cerr << "viewer.pixelThreshold=" << _pixelThreshold << endl;
//setBackgroundRole ( QPalette::Dark );
//setAutoFillBackground ( false );
setAttribute ( Qt::WA_OpaquePaintEvent );