本文整理汇总了C#中IScripture类的典型用法代码示例。如果您正苦于以下问题:C# IScripture类的具体用法?C# IScripture怎么用?C# IScripture使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IScripture类属于命名空间,在下文中一共展示了IScripture类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: CallCreateScrStyles
/// ------------------------------------------------------------------------------------
/// <summary>
/// Exposes the CreateScrStyles method
/// </summary>
/// ------------------------------------------------------------------------------------
static public void CallCreateScrStyles(IScripture scr, XmlNode teStyles)
{
using (ProgressDialogWithTask progressDlg = new ProgressDialogWithTask(Form.ActiveForm))
{
DummyTeStylesXmlAccessor acc = new DummyTeStylesXmlAccessor(scr, teStyles);
acc.InitLoading(progressDlg, scr, teStyles);
}
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:14,代码来源:TeStylesXmlAccessorTests.cs
示例2: TeScrNoteCategoriesInit
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="T:TeScrNoteCategoriesInit"/> class.
/// </summary>
/// <param name="progressDlg">The progress dialog.</param>
/// <param name="scr">The scripture object.</param>
/// <param name="categories">The categories.</param>
/// ------------------------------------------------------------------------------------
protected TeScrNoteCategoriesInit(IAdvInd4 progressDlg, IScripture scr,
XmlNode categories)
{
m_scr = scr;
m_progressDlg = progressDlg;
m_categories = categories;
m_userLocale = scr.Cache.LanguageWritingSystemFactoryAccessor.GetStrFromWs(scr.Cache.DefaultUserWs);
m_fallbackUserLocale = scr.Cache.FallbackUserLocale;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:17,代码来源:TeScrNoteCategoriesInit.cs
示例3: DbScrPassageControl
/// ------------------------------------------------------------------------------------
/// <summary>
/// Non-default constructor
/// </summary>
/// <param name="reference">Initial reference</param>
/// <param name="scr">Scripture project</param>
/// ------------------------------------------------------------------------------------
public DbScrPassageControl(ScrReference reference, IScripture scr) :
base(reference, scr as IScrProjMetaDataProvider, scr.Versification)
{
if (DesignMode)
return;
ScriptureObject = scr;
scr.BooksChanged += BooksChanged;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:16,代码来源:DbScrPassageControl.cs
示例4: TeScrNoteCategoriesInit
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="TeScrNoteCategoriesInit"/> class.
/// </summary>
/// <param name="progressDlg">The progress dialog.</param>
/// <param name="scr">The scripture object.</param>
/// <param name="categories">The categories.</param>
/// ------------------------------------------------------------------------------------
protected TeScrNoteCategoriesInit(IProgress progressDlg, IScripture scr,
XmlNode categories)
{
m_scr = scr;
m_servLoc = scr.Cache.ServiceLocator;
m_progressDlg = progressDlg;
m_categories = categories;
m_defUserWs = m_servLoc.WritingSystemManager.UserWs;
m_wsId = m_servLoc.WritingSystemManager.UserWritingSystem.Id;
m_fallbackUserWsId = WritingSystemServices.FallbackUserWsId;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:19,代码来源:TeScrNoteCategoriesInit.cs
示例5: TePageSetupDlg
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="T:TePageSetupDlg"/> class.
/// </summary>
/// <param name="wsUser">The user writing system.</param>
/// <param name="pgLayout">The page layout.</param>
/// <param name="scr">The Scripture object (which owns the publications).</param>
/// <param name="publication">The publication.</param>
/// <param name="division">The division. The NumberOfColumns in the division should be
/// set before calling this dialog.</param>
/// <param name="teMainWnd">TE main window (provides callbacks).</param>
/// <param name="helpTopicProvider">The help topic provider.</param>
/// <param name="units">The user's prefered measurement units.</param>
/// <param name="fIsTrialPub">if set to <c>true</c> view from which this dialog
/// was brought up is Trial Publication view.</param>
/// <param name="pubPageSizes">The page sizes available for publication.</param>
/// ------------------------------------------------------------------------------------
public TePageSetupDlg(int wsUser, IPubPageLayout pgLayout, IScripture scr,
IPublication publication, IPubDivision division, IPageSetupCallbacks teMainWnd,
IHelpTopicProvider helpTopicProvider, MsrSysType units, bool fIsTrialPub,
List<PubPageInfo> pubPageSizes) :
base(wsUser, pgLayout, scr, publication, division, teMainWnd, helpTopicProvider,
units, pubPageSizes)
{
m_fIsTrialPublication = fIsTrialPub;
if (!m_chkNonStdChoices.Checked) // following the standard
m_standardLeadingFactor = m_nudLineSpacing.Value / m_nudBaseCharSize.Value;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:28,代码来源:TePageSetupDlg.cs
示例6: Initialize
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes the scripture note import manager.
/// </summary>
/// ------------------------------------------------------------------------------------
public static void Initialize(IScripture scr, int bookNum, string alternateRfcWsDir)
{
s_scr = scr;
if (!string.IsNullOrEmpty(alternateRfcWsDir))
s_alternateRfcWsDir = alternateRfcWsDir;
CacheCheckIds();
if (bookNum != s_prevBookNum)
{
s_prevBookNum = bookNum;
s_annotationList = scr.BookAnnotationsOS[bookNum - 1];
s_existingAnnotations = new Dictionary<ScrNoteKey, IScrScriptureNote>();
foreach (IScrScriptureNote ann in s_annotationList.NotesOS)
s_existingAnnotations[ann.Key] = ann;
}
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:24,代码来源:ScrNoteImportManager.cs
示例7: GotoReferenceDialog
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="GotoReferenceDialog"/> class.
/// </summary>
/// <param name="reference">The initial reference to populate the control.</param>
/// <param name="scr">The Scripture object.</param>
/// <param name="helpProvider">The help provider.</param>
/// ------------------------------------------------------------------------------------
public GotoReferenceDialog(ScrReference reference, IScripture scr, IHelpTopicProvider helpProvider)
{
Logger.WriteEvent("Opening 'Goto Reference' dialog");
m_scripture = scr;
m_helpProvider = helpProvider;
//
// Required for Windows Form Designer support
//
InitializeComponent();
scrPassageControl = new DbScrPassageControl(reference, m_scripture);
scrPassageControl.Location = new System.Drawing.Point(16, 16);
scrPassageControl.Name = "scrPassageControl";
scrPassageControl.Size = new System.Drawing.Size(Width - 36, 24);
Controls.Add(scrPassageControl);
scrPassageControl.TabIndex = 0;
btn_OK.TabIndex = 1;
btn_cancel.TabIndex = 2;
btn_help.TabIndex = 3;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:29,代码来源:GotoReferenceDialog.cs
示例8: DummyTeKeyTermsInit
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="DummyTeKeyTermsInit"/> class.
/// </summary>
/// <param name="scr">The Scripture object.</param>
/// ------------------------------------------------------------------------------------
public DummyTeKeyTermsInit(IScripture scr) : base(scr)
{
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:9,代码来源:TeKeyTermsInitTests.cs
示例9: ImportWizard
/// ------------------------------------------------------------------------------------
/// <summary>
/// Constructor for runtime.
/// </summary>
/// <param name="langProjName">Name of the lang proj.</param>
/// <param name="scr">The Scripture object.</param>
/// <param name="styleSheet">The styleSheet</param>
/// <param name="helpTopicProvider">The help topic provider.</param>
/// <param name="app">The app.</param>
/// ------------------------------------------------------------------------------------
public ImportWizard(string langProjName, IScripture scr, FwStyleSheet styleSheet,
IHelpTopicProvider helpTopicProvider, IApp app) : this()
{
m_LangProjName = langProjName;
m_scr = scr;
m_helpTopicProvider = helpTopicProvider;
m_app = app;
m_StyleSheet = styleSheet;
m_resolver = new ConfirmOverlappingFileReplaceDialog(helpTopicProvider);
m_cache = scr.Cache;
// Attempt to get the default import settings.
m_settings = m_scr.FindOrCreateDefaultImportSettings(TypeOfImport.Unknown);
if (m_settings.ImportTypeEnum == TypeOfImport.Unknown)
m_settings.ImportTypeEnum = TypeOfImport.Paratext6;
InitializeScrImportSettings();
// Initialize controls based on settings provided
switch (m_settings.ImportTypeEnum)
{
case TypeOfImport.Paratext6:
rbParatext6.Checked = true;
break;
case TypeOfImport.Other:
rbOther.Checked = true;
break;
case TypeOfImport.Paratext5:
rbParatext5.Checked = true;
break;
}
if (m_helpTopicProvider == null)
m_btnHelp.Visible = false;
if (m_app != null)
{
m_LatestImportFolder = new RegistryStringSetting(FwSubKey.TE, m_scr.Cache.ProjectId.Name,
"LatestImportDirectory", string.Empty);
sfFileListBuilder.LatestImportFolder = m_LatestImportFolder.Value;
}
sfFileListBuilder.Initialize(m_helpTopicProvider, m_app);
if (m_StyleSheet != null)
{
m_scrViewHelper = new StyleListViewHelper(lvScrMappings, 1);
m_scrViewHelper.AddStyles(m_StyleSheet, MappingDetailsCtrl.AllPseudoStyles);
m_annotationViewHelper = new StyleListViewHelper(lvAnnotationMappings, 1);
m_annotationViewHelper.AddStyles(m_StyleSheet,
MappingDetailsCtrl.AllPseudoStyles);
}
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:60,代码来源:ImportWizard.cs
示例10: ImportDialog
///-------------------------------------------------------------------------------
/// <summary>
/// Constructor for import dialog, requiring a language project.
/// Use this constructor at run time.
/// </summary>
///-------------------------------------------------------------------------------
public ImportDialog(FwStyleSheet styleSheet, FdoCache cache, IScrImportSet settings,
IHelpTopicProvider helpTopicProvider, IApp app) : this()
{
m_StyleSheet = styleSheet;
m_helpTopicProvider = helpTopicProvider;
m_app = app;
m_scr = cache.LangProject.TranslatedScriptureOA;
m_importSettings = settings;
//InitBookNameList();
// Set the initial values for the controls from the static variables.
radImportEntire.Checked = ImportEntire;
radImportRange.Checked = !ImportEntire;
chkTranslation.Checked = ImportTranslation;
chkBackTranslation.Checked = ImportBackTranslation;
chkBookIntros.Checked = ImportBookIntros;
chkOther.Checked = ImportAnnotations;
// Restore any saved settings.
if (s_StartRef != null)
StartRef = s_StartRef;
else
SetStartRefToFirstImportableBook();
if (s_EndRef != null)
EndRef = s_EndRef;
else
SetEndRefToLastImportableBook();
// Finish constructing the ScrBookControl objects.
InitializeStartAndEndRefControls();
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:39,代码来源:ImportDialog.cs
示例11: ExportRtfDialog
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="ExportRtfDialog"/> class.
/// </summary>
/// <param name="cache">The cache.</param>
/// <param name="helpTopicProvider">The help topic provider.</param>
/// ------------------------------------------------------------------------------------
public ExportRtfDialog(FdoCache cache, IHelpTopicProvider helpTopicProvider)
{
//
// Required for Windows Form Designer support
//
InitializeComponent();
// If the current settings are for arabic digits then don't show the option
// to export them as arabic.
m_scr = cache.LangProject.TranslatedScriptureOA;
m_helpTopicProvider = helpTopicProvider;
// Set default export folder.
m_rtfFolder = new RegistryStringSetting(
Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments),
"ExportFolderForRTF", FwSubKey.TE);
string fileName = m_rtfFolder.Value;
m_fileDialog = new TeImportExportFileDialog(cache.ProjectId.Name, FileType.RTF);
// Append a filename if it was set to just a directory
if (Directory.Exists(fileName))
fileName = Path.Combine(fileName, m_fileDialog.DefaultFileName);
m_txtOutputFile.Text = fileName;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:32,代码来源:ExportRtfDialog.cs
示例12: Dispose
/// ------------------------------------------------------------------------------------
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// ------------------------------------------------------------------------------------
protected override void Dispose(bool disposing)
{
base.Dispose(disposing);
if (disposing)
ScriptureObject.BooksChanged -= BooksChanged;
ScriptureObject = null;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:12,代码来源:DbScrPassageControl.cs
示例13: MultipleFilterDlg
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="T:MultipleFilterDlg"/> class.
/// </summary>
/// ------------------------------------------------------------------------------------
public MultipleFilterDlg(FdoCache cache, IHelpTopicProvider helpTopicProviderp,
ICmFilter filter) : this()
{
m_helpTopicProvider = helpTopicProviderp;
m_cache = cache;
m_cellFactory = m_cache.ServiceLocator.GetInstance<ICmCellFactory>();
m_scr = m_cache.LangProject.TranslatedScriptureOA;
m_filter = filter;
// Initialize the enabled status of the group boxes.
chkStatus_CheckedChanged(null, null);
chkType_CheckedChanged(null, null);
chkScrRange_CheckedChanged(null, null);
// Initialize the beginning and ending default Scripture references.
int firstBook = 1;
int lastBook = BCVRef.LastBook;
if (m_scr.ScriptureBooksOS.Count > 0)
{
firstBook = m_scr.ScriptureBooksOS[0].CanonicalNum;
lastBook = m_scr.ScriptureBooksOS[m_scr.ScriptureBooksOS.Count - 1].CanonicalNum;
}
scrBookFrom.Initialize(new ScrReference(firstBook, 1, 1, m_scr.Versification));
scrBookTo.Initialize(new ScrReference(lastBook, 1, 0, m_scr.Versification).LastReferenceForBook);
// Update the controls from the filter in the database.
InitializeFromFilter();
chkCategory.Checked = tvCatagories.Load(m_cache, m_filter, null);
chkCategory_CheckedChanged(null, null);
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:36,代码来源:MultipleFilterDlg.cs
示例14: NotesDataEntryView
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="NotesDataEntryView"/> class.
/// </summary>
/// <param name="cache">Duh</param>
/// <param name="userView">The UserView that this view displays</param>
/// <param name="notesWnd">The notes window.</param>
/// ------------------------------------------------------------------------------------
public NotesDataEntryView(FdoCache cache, IUserView userView, FwMainWnd notesWnd) : base(cache)
{
m_scr = Cache.LangProject.TranslatedScriptureOA;
m_UserView = userView;
m_notesMainWnd = notesWnd;
BaseInfoBarCaption = userView.ViewNameShort;
ReadOnlyView = true;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:16,代码来源:NotesDataEntryView.cs
示例15: TeHeaderFooterVc
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="TeHeaderFooterVc"/> class.
/// </summary>
/// <param name="cache">DB Connection</param>
/// <param name="page">Page information</param>
/// <param name="wsDefault">ID of default writing system</param>
/// <param name="printDateTime">printing date/time</param>
/// <param name="filterInstance">book filter instance</param>
/// ------------------------------------------------------------------------------------
public TeHeaderFooterVc(FdoCache cache, IPageInfo page, int wsDefault,
DateTime printDateTime, int filterInstance)
: base(page, wsDefault, printDateTime, cache)
{
m_scr = m_cache.LangProject.TranslatedScriptureOA;
m_bookFilter = m_cache.ServiceLocator.GetInstance<IFilteredScrBookRepository>().GetFilterInstance(filterInstance);
m_autoAdjustColumns = true;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:18,代码来源:TeHeaderFooterVc.cs
示例16: BtConverter
/// ------------------------------------------------------------------------------------
/// <summary>
/// Make one for converting the specified paragraph.
/// </summary>
/// <param name="para">The paragraph.</param>
/// <param name="wsBt">The writing system for which to do the conversion.</param>
/// ------------------------------------------------------------------------------------
private BtConverter(IStTxtPara para, int wsBt)
{
m_para = para;
m_cache = para.Cache;
m_cpe = m_cache.ServiceLocator.UnicodeCharProps;
m_scr = para.Cache.LangProject.TranslatedScriptureOA;
m_wsBt = wsBt;
}
开发者ID:sillsdev,项目名称:FieldWorks,代码行数:15,代码来源:BtConverter.cs
示例17: NotesDataEntryView
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="NotesDataEntryView"/> class.
/// </summary>
/// <param name="cache">The cache.</param>
/// <param name="helpTopicProvider">The help topic provider.</param>
/// <param name="infoBarCaption">The info bar caption.</param>
/// <param name="notesWnd">The notes window.</param>
/// ------------------------------------------------------------------------------------
public NotesDataEntryView(FdoCache cache, IHelpTopicProvider helpTopicProvider,
string infoBarCaption, FwMainWnd notesWnd) : base(cache)
{
m_helpTopicProvider = helpTopicProvider;
m_scr = cache.LangProject.TranslatedScriptureOA;
m_notesMainWnd = notesWnd;
BaseInfoBarCaption = infoBarCaption;
ReadOnlyView = true;
}
开发者ID:bbriggs,项目名称:FieldWorks,代码行数:18,代码来源:NotesDataEntryView.cs
示例18: BtConverter
/// <summary>
/// Make one for converting the specified paragraph.
/// </summary>
/// <param name="para"></param>
public BtConverter(IStTxtPara para)
{
m_para = para;
m_cache = para.Cache;
kflidFT = StTxtPara.SegmentFreeTranslationFlid(m_cache);
kflidSegments = StTxtPara.SegmentsFlid(m_cache);
m_cpe = m_cache.LanguageWritingSystemFactoryAccessor.UnicodeCharProps;
m_scr = para.Cache.LangProject.TranslatedScriptureOA;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:13,代码来源:BtConverter.cs
示例19: TeHeaderFooterVc
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="TeHeaderFooterVc"/> class.
/// </summary>
/// <param name="cache">DB Connection</param>
/// <param name="page">Page information</param>
/// <param name="wsDefault">ID of default writing system</param>
/// <param name="printDateTime">printing date/time</param>
/// <param name="filterInstance">book filter instance</param>
/// <param name="sectionsTag">The sections tag.</param>
/// ------------------------------------------------------------------------------------
public TeHeaderFooterVc(FdoCache cache, IPageInfo page, int wsDefault,
DateTime printDateTime, int filterInstance, int sectionsTag)
: base(page, wsDefault, printDateTime, cache)
{
m_scr = m_cache.LangProject.TranslatedScriptureOA;
m_bookFilter = FilteredScrBooks.GetFilterInstance(m_cache, filterInstance);
m_autoAdjustColumns = true;
m_sectionsTag = sectionsTag;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:20,代码来源:TeHeaderFooterVc.cs
示例20: FixtureSetup
public override void FixtureSetup()
{
CheckDisposed();
base.FixtureSetup();
m_fdoCache = FdoCache.Create("TestLangProj");
m_scr = m_fdoCache.LangProject.TranslatedScriptureOA;
// For these tests we don't need to run InstallLanguage.
m_wsf = m_fdoCache.LanguageWritingSystemFactoryAccessor;
m_wsf.BypassInstall = true;
}
开发者ID:sillsdev,项目名称:WorldPad,代码行数:12,代码来源:FwStyleSheetTests.cs
注:本文中的IScripture类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论