Example #1
0
 /// <summary>
 /// Sets the temporary frame by using subzone preset
 /// </summary>
 /// <param name="sub">The sub.</param>
 /// <param name="startPosition">The start position.</param>
 /// <returns></returns>
 public cursorZone setTempFrame(cursorSubzoneFrame sub, textCursorZoneCorner startPosition = textCursorZoneCorner.none)
 {
     tempFrame    = new cursorZone(this.frame, sub);
     useTempFrame = true;
     moveToCorner(startPosition);
     return(tempFrame);
 }
Example #2
0
        /// <summary>
        /// Subzone frame by preset <see cref="cursorZone"/>
        /// </summary>
        /// <param name="sourceZone">The source zone.</param>
        /// <param name="sz">Subzone preset</param>
        public cursorZone(cursorZone sourceZone, cursorSubzoneFrame sz) : base(sourceZone.width, sourceZone.margin.leftAndRight, sourceZone.padding.leftAndRight)
        {
            margin.Learn(sourceZone.margin);
            padding.Learn(sourceZone.padding);

            height = sourceZone.height;
            switch (sz)
            {
            case cursorSubzoneFrame.fullFrame:
                width = sourceZone.width;
                break;

            case cursorSubzoneFrame.h1:
                width = sourceZone.width / 2;
                break;

            case cursorSubzoneFrame.h2:
                margin.left = sourceZone.width / 2;
                width       = sourceZone.width - margin.left;
                break;

            case cursorSubzoneFrame.q1:
                width = sourceZone.width / 4;
                break;

            case cursorSubzoneFrame.q2:
                width       = sourceZone.width / 4;
                margin.left = width;
                break;

            case cursorSubzoneFrame.q3:
                width       = sourceZone.width / 4;
                margin.left = width * 2;
                break;

            case cursorSubzoneFrame.q4:
                width       = sourceZone.width / 4;
                margin.left = sourceZone.width - width;
                break;
            }
        }
Example #3
0
 /// <summary>
 /// Setting dsa_zoneFrame argument
 /// </summary>
 /// <param name="zoneFrame">Value for dsa_zoneFrame</param>
 /// <returns>Instruction</returns>
 public docScriptInstruction arg(cursorSubzoneFrame zoneFrame)
 {
     this.add(docScriptArguments.dsa_zoneFrame, zoneFrame);
     return(this);
 }