Español
Wünsche y Sugerencias

Concepto: Negative Größenangabe para Ventana y CreateWindow/Dlg

 
Concepto: Gibt uno en Ventana en el Parametern para el Größe, una negativen Valor a, entonces son el inneren Ausmasse gemeint.

SetWindowPos ebenfalls con diesem "Feature" ausstatten wäre imho auch sinnvoll.

Das Ejemplo hier verdeutlicht el problema:
KompilierenMarcaSeparación
window 100,100 - 100,100
rectangle 0,0 - 99,99
waitInput
end<
pre>

producido logischerweise:



Wobei wünschenswert wäre, si nun una "xprofanes" Gegenmittel gäbe. Also en el Principio algo como  
[...]  hier.

5 kB
Hochgeladen:04.12.2008
Ladeanzahl191
Descargar
 
04.12.2008  
 




Jörg
Sellmeyer
Keine Idea, por qué que aquí en hecho es. Yo finde el Concepto super. Tal vez no con negativen Pagar, pero con un zusätzlichen Parámetro. Oder Meinetwegen auch con Conjunto("Client",1). danach voluntad entonces todos Ventana, así producido, dass el Größenangabe como Clientgröße gewertet se.
 
XProfan X3
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
30.05.2018  
 




RGH
... y ya hay Ideen para una mögliches XProfan X5! ;)

Como debería Yo veces schauen, si el Wondows-API así algo hergibt.

(Aber sólo mache Yo veces el USB-Sticks para el Abonnenten fertig y wende mich entonces veces otra vez el FreeProfan-Versionen a ...)

Saludo
Roland
 
XProfan X3
Intel Duo E8400 3,0 GHz / 4 GB RAM / 1000 GB HDD - ATI Radeon HD 4770 512 MB - Windows 7 Home Premium 32Bit - XProfan X4
31.05.2018  
 




Jörg
Sellmeyer
Mit AdjustWindowRect erreicht uno como ya Einiges. Leider se el Menü a Clientarea gerechnet y yo such grad, wo uno el Menühöhe auslesen kann.
 
XProfan X3
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
31.05.2018  
 




Jörg
Sellmeyer
So puede ser schonmal el Standardsachen erschlagen:
 $H Windows.ph
 $H structs.ph
'RECT = Left&,Top&,Right&,Bottom&;
'  WS_BORDER = $800000;
'  WS_DLGFRAME = $400000;
'  WS_VSCROLL = $200000;
'  WS_HSCROLL = $100000;
'  WS_SYSMENU = $80000;
'  WS_THICKFRAME = $40000;
'  WS_DLGFRAME = $400000;
'  WS_EX_CLIENTEDGE = $200;
'  WS_EX_STATICEDGE = $20000;
Struct AdjustWindowRect = ~Rect

SubProc Crear.XWindow

    'Parámetros Handle hParent, String sClass, sText ,Int iLeft, iTop, iWidth, iHeight,fMenu
    traceoff

    If %pcount = 4

        Parámetros Handle hParent, String sText ,Int iWidth, iHeight
        Declarar Int iLeft, iTop
        Var Int fCenter = 1

    Más

        Parámetros Handle hParent, String sClass, sText ,Int iLeft, iTop, iWidth, iHeight

    EndIf

    Declarar Mem WindowSize,Int fMenu
    Dim WindowSize,AdjustWindowRect

    With WindowSize

        .Left& = iLeft
        .Top& = iTop
        .Right& = iWidth + iLeft
        .Bottom& = iHeight + iTop

    EndWith

    With WindowSize

        If hParent = 0

            fMenu = Not((%windowstyle & %10000))
            ~AdjustWindowRect(WindowSize,~WS_CAPTION | ~WS_THICKFRAME,fMenu)
            'fMenu son a, si una fenstermenü disponible es

            If SizeOf(fCenter) > 0

                Ventana (.Right& - .Left&),(.Bottom& - .Top&)

            Más

                Ventana .Left&,.Top& - (.Right& - .Left&),(.Bottom& - .Top&)

            EndIf

            SetText %hwnd,sText
            Volver %hwnd

        ElseIf Upper$(sClass) = "DIÁLOGO"

            ~AdjustWindowRect(WindowSize,~WS_CAPTION | ~WS_DLGFRAME,fMenu)
            Volver Crear("Dialog",hParent,sText,.Left&,.Top&,(.Right& - .Left&),(.Bottom& - .Top&))

        ElseIf Upper$(sClass) = "WINDOW"

            ~AdjustWindowRect(WindowSize,~WS_CAPTION | ~WS_THICKFRAME,fMenu)
            Volver Crear("Window",hParent,sText,.Left&,.Top&,(.Right& - .Left&),(.Bottom& - .Top&))

        ElseIf Upper$(sClass) = "CHILDWINDOW"

            ~AdjustWindowRect(WindowSize,~WS_CAPTION | ~WS_THICKFRAME,fMenu)
            Volver Crear("ChildWindow",hParent,sText,.Left&,.Top&,(.Right& - .Left&),(.Bottom& - .Top&))

        EndIf

    EndWith

ENDPROC

If &GetTickCount Mod 2

    Ventana de Estilo %11111
    Var Handle hwnd = Crear("XWindow",0,"","Hauptfenster",100,100,800,600)

Más

    Ventana de Estilo %11111
    Var Handle hwnd = Crear("XWindow",0,"Hauptfenster zentriert",800,600)

EndIf

Imprimir bin$(%windowstyle & ~WS_CAPTION)
Var Handle hDlg1 = Crear("XWindow",%hwnd,"Dialog","Dialog",%winleft + 250,%wintop + 150,400,300)
Var Handle hDlg2 = Crear("XWindow",%hwnd,"Window","Fenster",%winleft + 350,%wintop + 300,330,240)
Var Handle hDlg3 = Crear("XWindow",%hwnd,"ChildWindow","ChildWindow",50,350,300,200)
Imprimir "Hauptfenster:",%winleft,%wintop,Width(hwnd),Height(hwnd)
Imprimir "Dialog",Width(hDlg1),Height(hDlg1)
Imprimir "Window",Width(hDlg2),Height(hDlg2)
Imprimir "ChildWindow",Width(hDlg3),Height(hDlg3)

Mientras que 1

    WaitInput

Wend


Mühsamer Será mejor que te va, el ganzen möglichen Stilarten a berücksichtigen.
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
31.05.2018  
 



Würde uno simplemente el inneren Maße de los Äußeren abziehen, entonces debería uno el ganzen Stile oder Randdicken no mehr auswerten como el Differenzen el Notwendige ya hergeben.
 
31.05.2018  
 




Jörg
Sellmeyer
Sí - aber antes Erstellung la ventana, son el inneren Maße sí todavía no bekannt. Und el voluntad entonces eben por AdjustWindowRect mittels el Stile gesetzt.
Se puede natürlich bastante brachial sólo el jeweilige Ventana redactar y luego con SetWindowPos korrigieren. Aber schön es anders...
 
XProfan X3
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
31.05.2018  
 



Schon klar,

lo restos el Abwägung si "schneller" y "einfacher", una Control sólo unsichtbar a erzeugen y luego a el richtige Punto a bringen en lugar de viele Werte (möglicherweise de el Registry) a ermitteln en el Unwissen si en allen OS el así auch gleichermaßen ausreichend es.

Meiner Vermutung después de es una simples Ventana- y Clientrect simplemente "effizienter" y una doch bastante analoge Messung.
 
31.05.2018  
 




Jörg
Sellmeyer
Das bliebe entonces nachzumessen...
 
XProfan X3
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
31.05.2018  
 




Jörg
Sellmeyer
Ach sí: en el Auslesen el Menühöhe kommst du no herum, como el Menü sí a Client-Area zählt.
 
Windows XP SP2 XProfan X4
... und hier mal was ganz anderes als Profan ...
07.06.2018  
 



Respuesta


Título del Tema, max. 100 Signo.
 

Systemprofile:

Kein Systemprofil creado. [anlegen]

XProfan:

 Contribución  Font  Smilies  ▼ 

Bitte registro en una Contribución a verfassen.
 

Tema opciones

6.191 Views

Untitledvor 0 min.
Stringray05.01.2022
Rolf Koch15.01.2020
Thomas Zielinski06.09.2019
Pedro Miguel17.05.2019
Más...

Themeninformationen

Dieses Thema ha 3 subscriber:

Jörg Sellmeyer (6x)
iF (3x)
RGH (1x)


Admins  |  AGB  |  Applications  |  Autores  |  Chat  |  Política de Privacidad  |  Descargar  |  Entrance  |  Ayuda  |  Merchantportal  |  Pie de imprenta  |  Mart  |  Interfaces  |  SDK  |  Services  |  Juegos  |  Búsqueda  |  Support

Ein Projekt aller XProfan, el lo son!


Mi XProfan
Privado Noticias
Eigenes Ablageforum
Temas-Merkliste
Eigene Beiträge
Eigene Temas
Zwischenablage
Cancelar
 Deutsch English Français Español Italia
Traducciones

Política de Privacidad


Wir uso Cookies sólo como Session-Cookies wegen el technischen Notwendigkeit y en uns hay no Cookies de Drittanbietern.

Wenn du hier en unsere Webseite klickst oder navigierst, stimmst du unserer Erfassung de Informationen en unseren Cookies en XProfan.Net a.

Weitere Informationen a unseren Cookies y dazu, como du el Kontrolle darüber behältst, findest du en unserer nachfolgenden Datenschutzerklärung.


einverstandenDatenschutzerklärung
Yo möchte no Cookie