예제 #1
0
        public void Reset()
        {
            myMarker.UnmarkAll();

            mySelectedElement = null;
            myTable           = null;

            myDimension = CellDimension.None;

            mySkipColumns  = null;
            mySkipRows     = null;
            myRowHeader    = -1;
            myColumnHeader = -1;
            mySeriesName   = null;
        }
예제 #2
0
        /// <summary>
        /// Marks the given HTML table cell element and its siblings according to the expansion settings.
        /// If the given HtmlElement is not within a HTML table this call is ignored.
        /// </summary>
        public void Mark(IHtmlElement element)
        {
            Contract.RequiresNotNull(element, "element");

            var tableCandidate = HtmlTable.GetByElement(element);

            if (tableCandidate == null)
            {
                return;
            }

            myElement = ( HtmlElementAdapter )element;

            Table = tableCandidate;

            Apply();
        }
예제 #3
0
        public void Detach()
        {
            if (Document == null)
            {
                return;
            }

            Document.Document.Click -= HtmlDocument_Click;

            mySelectedElement = null;
            myPath            = null;

            // We have to unmark all because anyway with new document the HtmlElements inside the Marker are invalid.
            // We do not call Reset() in order to keep the settings in the Marker (e.g. HtmlTableMarker).
            Marker.Unmark();

            Document.Document.Body.SetAttribute("RaynMakerHtmlMarkupBehavior", null);

            Document = null;
        }