• Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    Tcheko
    Posts: 538 from 2003/2/25
    From: France
    Quote:

    igracki wrote:
    I uploaded a new version of WinAction
    Its now a full implementation of Intuition's WindowAction() function.
    Code:

    0:00.02 [ 0] Dev:ecx/my/WinAction> WinAction ?
    NAME/A,ACTION/A,X=LEFT/N,Y=TOP/N,W=WIDTH/N,H=HEIGHT/N: ?

    Perform an action to a window
    NAME/A: Name of the window, case sensitive
    ACTION/A: One of the actions below, not case sensitive
    X=LEFT, Y=TOP, W=WIDTH, H=HEIGHT: Only for the actions BOX, MOVE and SIZE

    Possible window actions are:
    ACTIVATE - activate it
    BACK - put it to the back
    FRONT - put it to the front
    FBACK - put all windows of the same "family" to back
    FFRONT - put all windows of the same "family" to front
    MIN - minimize it
    MAX - maximize it
    RESTORE - restore size and pos
    OPENMENU - open window's menu
    HIDE - hide the window
    SHOW - show the window
    ZIP - zip the window
    CLOSE - send an IDCMP_CLOSEWINDOW

    Special actions with parameters
    BOX - change the window's position and size
    Example: WinAction TestWin BOX x=100 y=234 w=555 h=333
    MOVE - move the window's left and top position
    Example: WinAction TestWin MOVE x=100 y=-200
    SIZE - resize the window, the values will be ADDED/SUBTRACTED!
    Example: WinAction TestWin SIZE 222 -111



    Would be nice to have a way to query the screen size for doing some math for placing the window on a corner for example.
    Quelque soit le chemin que tu prendras dans la vie, sache que tu auras des ampoules aux pieds.
    -------
    I need to practice my Kung Fu.
  • »05.08.24 - 19:01
    Profile Visit Website