public void UpdateRectangle()
            {
                // create a new bounds that contains both the press and current
                // drag point.
                RectangleFx r = RectangleFx.Empty;

                r = PUtil.AddPointToRect(r, pressPoint);
                r = PUtil.AddPointToRect(r, dragPoint);

                // Set the rectangles bounds.
                rectangle.PathReference.Reset();
                rectangle.AddRectangle(r.X, r.Y, r.Width, r.Height);
            }
        /// <summary>
        /// Update the marquee bounds based on the given event data.
        /// </summary>
        /// <param name="e">A PInputEventArgs that contains the event data.</param>
        protected virtual void UpdateMarquee(PInputEventArgs e)
        {
            RectangleF r = RectangleF.Empty;

            if (marqueeParent is PCamera)
            {
                r = PUtil.AddPointToRect(r, canvasPressPt);
                r = PUtil.AddPointToRect(r, e.CanvasPosition);
            }
            else
            {
                r = PUtil.AddPointToRect(r, presspt);
                r = PUtil.AddPointToRect(r, e.Position);
            }

            r = marquee.GlobalToLocal(r);
            marquee.Reset();
            SetSafeMarqueePen(r.Width, r.Height);
            marquee.AddRectangle(r.X, r.Y, r.Width, r.Height);

            r = RectangleF.Empty;
            r = PUtil.AddPointToRect(r, presspt);
            r = PUtil.AddPointToRect(r, e.Position);

            allItems.Clear();
            PNodeFilter filter = CreateNodeFilter(r);

            foreach (PNode parent in selectableParents)
            {
                PNodeList items;
                if (parent is PCamera)
                {
                    items = new PNodeList();
                    PCamera cameraParent = (PCamera)parent;
                    for (int i = 0; i < cameraParent.LayerCount; i++)
                    {
                        cameraParent.GetLayer(i).GetAllNodes(filter, items);
                    }
                }
                else
                {
                    items = parent.GetAllNodes(filter, null);
                }

                foreach (PNode node in items)
                {
                    allItems.Add(node, true);
                }
            }
        }