示例#1
0
        public SimpleStyleSheet()
        {
            ITsPropsBldr tpb = (ITsPropsBldr) new FwKernelLib.TsPropsBldrClass();

            m_ttpNormal = tpb.GetTextProps();             // normal has nothing defined, use system defaults.
            tpb.SetIntPropValues((int)FwKernelLib.FwTextPropType.ktptForeColor, (int)FwKernelLib.FwTextPropVar.ktpvDefault,
                                 (int)ViewSampleVc.RGB(Color.Red));
            tpb.SetIntPropValues((int)FwKernelLib.FwTextPropType.ktptSuperscript, (int)FwKernelLib.FwTextPropVar.ktpvEnum,
                                 (int)FwKernelLib.FwSuperscriptVal.kssvSuper);
            m_ttpVerseNumber = tpb.GetTextProps();
        }
示例#2
0
        public override void MakeRoot()
        {
            m_rootb = (IVwRootBox) new FwViews.VwRootBoxClass();
            m_rootb.SetSite(this);

            m_sda = (ISilDataAccess) new FwViews.VwCacheDaClass();
            // Usually not here, but in some application global passed to each view.
            m_wsf = (ILgWritingSystemFactory) new FwLanguage.LgWritingSystemFactoryClass();
            m_sda.set_WritingSystemFactory(m_wsf);
            m_rootb.set_DataAccess(m_sda);

            m_vc = new ViewSampleVc();             // Before LoadData, which sets some of its properties.

            LoadData("data.xml");

            m_rootb.SetRootObject(khvoBook, m_vc, ViewSampleVc.kfrBook, new SimpleStyleSheet());
            m_fRootboxMade   = true;
            m_dxdLayoutWidth = -50000;             // Don't try to draw until we get OnSize and do layout.
        }
示例#3
0
		public override void MakeRoot()
		{
			m_rootb = (IVwRootBox)new FwViews.VwRootBoxClass();
			m_rootb.SetSite(this);

			m_sda = (ISilDataAccess) new FwViews.VwCacheDaClass();
			// Usually not here, but in some application global passed to each view.
			m_wsf = (ILgWritingSystemFactory) new FwLanguage.LgWritingSystemFactoryClass();
			m_sda.set_WritingSystemFactory(m_wsf);
			m_rootb.set_DataAccess(m_sda);

			m_vc = new ViewSampleVc(); // Before LoadData, which sets some of its properties.

			LoadData("data.xml");

			m_rootb.SetRootObject(khvoBook, m_vc, ViewSampleVc.kfrBook, new SimpleStyleSheet());
			m_fRootboxMade = true;
			m_dxdLayoutWidth = -50000; // Don't try to draw until we get OnSize and do layout.
		}