void CPrinterInfo::ReadSettings(void) { // Read our overrides. m_Record.m_nCopies = GetProfileInt(ENTRY_Copies, m_Record.m_nCopies); m_Record.m_nOrientation = GetProfileInt(ENTRY_Orientation, m_Record.m_nOrientation); m_Record.m_nTractor = GetProfileInt(ENTRY_Tractor, m_Record.m_nTractor); if (m_nOrientationType == PORTRAIT) { SetLeftMargin(GetProfileFixed(ENTRY_LeftMargin, m_PhysicalMargins.Left)); SetTopMargin(GetProfileFixed(ENTRY_TopMargin, m_PhysicalMargins.Top)); SetRightMargin(GetProfileFixed(ENTRY_RightMargin, m_PhysicalMargins.Right)); SetBottomMargin(GetProfileFixed(ENTRY_BottomMargin, m_PhysicalMargins.Bottom)); SetLeftOffset(GetProfileFixed(ENTRY_LeftOffset, m_Record.m_OriginOffset.x)); SetTopOffset(GetProfileFixed(ENTRY_TopOffset, m_Record.m_OriginOffset.y)); } else { SetLeftMargin(GetProfileFixed(ENTRY_LeftMarginLandscape, m_PhysicalMargins.Left)); SetTopMargin(GetProfileFixed(ENTRY_TopMarginLandscape, m_PhysicalMargins.Top)); SetRightMargin(GetProfileFixed(ENTRY_RightMarginLandscape, m_PhysicalMargins.Right)); SetBottomMargin(GetProfileFixed(ENTRY_BottomMarginLandscape, m_PhysicalMargins.Bottom)); SetLeftOffset(GetProfileFixed(ENTRY_LeftOffsetLandscape, m_Record.m_OriginOffset.x)); SetTopOffset(GetProfileFixed(ENTRY_TopOffsetLandscape, m_Record.m_OriginOffset.y)); } // Read our standard values. FastBitmaps(GetProfileInt(ENTRY_FastBitmaps, GetDefaultFastBitmaps())); SetOutlineGamma(GetProfileInt(ENTRY_OutlineGammaValue, DEFAULT_OUTLINE_GAMMA)); m_Record.m_nBitmapGamma = GetProfileInt(ENTRY_GammaValue, DEFAULT_BITMAP_GAMMA); m_Record.m_nFastBitmapGamma = GetProfileInt(ENTRY_FastBitmapGammaValue, DEFAULT_FAST_BITMAP_GAMMA); UpdateBitmapGamma(); SetPostScriptType(GetProfileInt(ENTRY_PostscriptType, m_nDefaultPostScriptType)); int nDefaultEnvelopePosition = (m_Record.m_nTractor == 1) ? (ENVELOPE_Wide | ENVELOPE_FlapUp | ENVELOPE_Center | ENVELOPE_RRotate) : (IsDeskJet() ? (ENVELOPE_FlapUp | ENVELOPE_Right) : (ENVELOPE_FlapDown | ENVELOPE_Center)); SetDefaultEnvelopePosition(GetProfileInt(ENTRY_DefaultEnvelopePosition, nDefaultEnvelopePosition)); SetEnvelopePosition(GetProfileInt(ENTRY_EnvelopePosition, GetDefaultEnvelopePosition())); ReverseLandscape(GetProfileInt(ENTRY_UseReverseLandscape, GetDefaultReverseLandscape())); SetDoubleSidedType(GetProfileInt(ENTRY_DoubleSidedType, 0)); SetPrintInstructions(GetProfileInt(ENTRY_PrintInstructions, DEFAULT_PRINT_INSTRUCTIONS)); SetPrintAsBitmap((BOOL)(GetProfileInt(ENTRY_FlagPrintAsBitmap, FALSE))); }
void CLCDScrollingText::ResetUpdate(void) { m_eState = STATE_START_DELAY; m_dwEllapsedTime = 0; m_dwLastUpdate = GetTickCount(); m_nScrollingDistance = -1; m_fTotalDistance = 0; SetLeftMargin(0); SetLogicalOrigin(0, 0); CLCDText::ResetUpdate(); }