Package com.sun.star.awt

Examples of com.sun.star.awt.Point


                XAccessibleContext xPanel = at.getAccessibleObjectForRole(xRoot, AccessibleRole.PANEL);
                XAccessibleComponent xPanelCont = (XAccessibleComponent) UnoRuntime.queryInterface(XAccessibleComponent.class, xPanel);

                // the position of the panel
                Point point = xPanelCont.getLocationOnScreen();

                // the range of the panel
                Rectangle rect = xPanelCont.getBounds();

                try {
View Full Code Here


            else
                nYTCPos = nMaxRowY + cVertDistance;
            nYDBPos = nYTCPos + nTCHeight;
            nXDBPos = cXOffset;
            nXTCPos = cXOffset;
            this.LabelControlList[a].setPosition(new Point(cXOffset, nYTCPos));
            this.DBControlList[a].setPosition(new Point(cXOffset, nYDBPos));
            bIsFirstRun = true;
            if (nDBWidth > nTCWidth)
                checkOuterPoints(nXDBPos, nDBWidth, nYDBPos, nDBHeight, true);
            else
                checkOuterPoints(nXDBPos, nTCWidth, nYDBPos, nDBHeight, true);
View Full Code Here

        for (int i = StartIndex; i <= EndIndex; i++){
            int nControlBaseWidth = 0;
            curDBControl = this.DBControlList[i];
            curLabelControl = this.LabelControlList[i];
            if (i != StartIndex){
                curLabelControl.setPosition( new Point(iLocTCPosX, curLabelControl.getPosition().Y));
                curDBControl.setPosition( new Point(iLocTCPosX, curLabelControl.getPosition().Y + nTCHeight));
            }
            if (((curLabelControl.getSize().Width > curDBControl.getSize().Width)) && (WidthFactor > 0))
                nControlBaseWidth = curLabelControl.getSize().Width;
            else
                nControlBaseWidth = curDBControl.getSize().Width;
View Full Code Here

    private void resetDBShape(Shape _curDBControl, int iXPos){
        int nYDBPos = _curDBControl.getPosition().Y;
        nDBWidth = _curDBControl.getSize().Width;
        nDBHeight = _curDBControl.getSize().Height;
        _curDBControl.setPosition(new Point(iXPos, nYDBPos));
    }
View Full Code Here


    private void insertLabel(int i, int _iAlign){
    try {
        if (bControlsareCreated){
            LabelControlList[i].setPosition(new Point(nXTCPos, nYTCPos));
            if (icurArrangement != FormWizard.SOCOLUMNARLEFT){
                nTCWidth = LabelControlList[i].getPreferredWidth(FieldColumns[i].FieldTitle);
                LabelControlList[i].setSize(new Size(nTCWidth, nTCHeight));
            }
            else
                nTCWidth = LabelControlList[i].getSize().Width;
        }
        else{
            Point aPoint = new Point(nXTCPos, nYTCPos);
            Size aSize = new Size(nTCWidth,nTCHeight);
            this.LabelControlList[i] = new Control(oFormHandler, xFormName, FormHandler.SOLABEL, FieldColumns[i].FieldName, aPoint, aSize);
            if (bIsVeryFirstRun){
                if (icurArrangement == FormWizard.SOCOLUMNARTOP)
                    nYDBPos = nYTCPos + nTCHeight;
View Full Code Here

    }}


    private void insertDBControl(int i ){
    try {
        Point aPoint = new Point(nXDBPos, nYDBPos);
        if (bControlsareCreated)
            DBControlList[i].setPosition(aPoint);
        else{
            if (FieldColumns[i].FieldType == DataType.TIMESTAMP)
                DBControlList[i] = new TimeStampControl(new Resource(xMSF, "FormWizard", "dbw"), oFormHandler, xFormName, FieldColumns[i].FieldName, aPoint);
            else{      
                DBControlList[i] = new DatabaseControl(oFormHandler, xFormName, FieldColumns[i].FieldName, FieldColumns[i].FieldType, aPoint);
                if (DBControlList[i].getControlType() == FormHandler.SOCHECKBOX)
                    DBControlList[i].setPropertyValue("Label", "");
            }
        }
        this.curDBControl = DBControlList[i];
        nDBHeight = curDBControl.getDBHeight();
        nDBWidth = curDBControl.getDBWidth();
        if (FieldColumns[i].FieldType != DataType.TIMESTAMP)
            curDBControl.setSize(new Size(nDBWidth, nDBHeight));
        if (curDBControl.getControlType() == FormHandler.SOCHECKBOX){
            nYDBPos = nYDBPos +(int)((oFormHandler.getDBRefHeight() - nDBHeight)/2);
            aPoint = new Point(nXDBPos, nYDBPos);
            curDBControl.setPosition(aPoint);
        }
        checkOuterPoints(nXDBPos, nDBWidth, nYDBPos, nDBHeight, true);
        curDBControl.setPropertyValue("Border", NBorderType);
    } catch (Exception e) {
View Full Code Here

    }
   
   
    public void adjustYPositions(int _diffY){
        for (int i = 0; i < DBControlList.length; i++){
            Point aPoint = DBControlList[i].getPosition();
            DBControlList[i].setPosition(new Point(aPoint.X, aPoint.Y - _diffY));
            aPoint = this.LabelControlList[i].getPosition();
            LabelControlList[i].setPosition(new Point(aPoint.X, aPoint.Y - _diffY));
        }
        nMaxDBYPos =- _diffY;
        cYOffset =- _diffY;
    }
View Full Code Here

                XAccessibleContext xPanel = at.getAccessibleObjectForRole(xRoot, AccessibleRole.PANEL);
                XAccessibleComponent xPanelCont = (XAccessibleComponent) UnoRuntime.queryInterface(XAccessibleComponent.class, xPanel);

                // the position of the panel
                Point point = xPanelCont.getLocationOnScreen();

                // the range of the panel
                Rectangle rect = xPanelCont.getBounds();

                try {
View Full Code Here

        XControlShape xShape = (XControlShape)UnoRuntime.queryInterface( XControlShape.class,
            xDocAsFactory.createInstance( "com.sun.star.drawing.ControlShape" ) );

        // position and size of the shape
        xShape.setSize( new Size( nWidth * 100, nHeight * 100 ) );
        xShape.setPosition( new Point( nXPos * 100, nYPos * 100 ) );

        // adjust the anchor so that the control is tied to the page
        XPropertySet xShapeProps = dbfTools.queryPropertySet( xShape );
        TextContentAnchorType eAnchorType = TextContentAnchorType.AT_PARAGRAPH;
        xShapeProps.setPropertyValue( "AnchorType", eAnchorType );
View Full Code Here

        String objName = "FileControl";
       
        XControlShape aShape = null;
       
        Size size = new Size();
        Point position = new Point();
        XControlModel aControl = null;
       
        //get MSF
        XMultiServiceFactory oDocMSF = (XMultiServiceFactory) UnoRuntime.queryInterface(
            XMultiServiceFactory.class,
View Full Code Here

TOP

Related Classes of com.sun.star.awt.Point

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.