GetHelpString() public static method

Return a help topic or help file path.
public static GetHelpString ( string stid ) : string
stid string String resource id
return string
Esempio n. 1
0
        /// ------------------------------------------------------------------------------------
        /// <summary>
        /// Returns the help urls for each tab on the styles dialog (currently 5 tabs)
        /// </summary>
        /// <returns></returns>
        /// ------------------------------------------------------------------------------------
        public override string[] GetStyleDlgHelpUrls()
        {
            CheckDisposed();

            return(new string[] {
                TeResourceHelper.GetHelpString("khtpTeStylesGeneral"),
                TeResourceHelper.GetHelpString("khtpTeStylesFont"),
                TeResourceHelper.GetHelpString("khtpTeStylesParagraph"),
                TeResourceHelper.GetHelpString("khtpTeStylesBullets"),
                TeResourceHelper.GetHelpString("khtpTeStylesBorder")
            });
        }
Esempio n. 2
0
        /// ------------------------------------------------------------------------------------
        /// <summary>
        /// Gets a help file URL or topic
        /// </summary>
        /// <param name="stid"></param>
        /// <returns>The requested string</returns>
        /// ------------------------------------------------------------------------------------
        public override string GetHelpString(string stid)
        {
            // First check if the stid starts with the marker that tells us the user is wanting
            // help on a particular style displayed in the styles combo box. If so, then find
            // the correct URL for the help topic of that style's example.
            const string kStylePrefix = "style:";

            if (stid.StartsWith(kStylePrefix))
            {
                return(TeStylesXmlAccessor.GetHelpTopicForStyle(stid.Substring(kStylePrefix.Length)));
            }
            if (stid.StartsWith("khtpScrChecks_"))
            {
                return(TeResourceHelper.GetHelpString(stid) ?? base.GetHelpString("khtpScrChecksUndocumented"));
            }

            return(TeResourceHelper.GetHelpString(stid) ?? base.GetHelpString(stid));
        }
Esempio n. 3
0
        /// ------------------------------------------------------------------------------------
        /// <summary>
        /// Gets a help file URL or topic
        /// </summary>
        /// <param name="stid"></param>
        /// <param name="iKey"></param>
        /// <returns>The requested string</returns>
        /// ------------------------------------------------------------------------------------
        public override string GetHelpString(string stid, int iKey)
        {
            CheckDisposed();

            // First check if the stid starts with the marker that tells us the user is wanting
            // help on a particular style displayed in the styles combo box. If so, then find
            // the correct URL for the help topic of that style's example.
            if (stid.StartsWith("style:"))
            {
                return(TeStylesXmlAccessor.GetHelpTopicForStyle(stid.Substring(6)));
            }

            string helpString = TeResourceHelper.GetHelpString(stid);

            if (helpString != null)
            {
                return(helpString);
            }

            return(base.GetHelpString(stid, iKey));
        }