… und schließlich entdeckte Kolumbus SS_CENTERIMAGE

Wer wollte nicht  schon immer mal einen Text in einem Static-Control zentrieren. Nein nicht horizontal mit SS_CENTER, das weiß ja jeder ;-). Es geht um das vertikale zentrieren.

Und wieder lernt man etwas dazu, was man einfach die letzten Jahre überlesen hat.

SS_CENTERIMAGE Specifies that a bitmap is centered in the static control that contains it. The control is not resized, so that a bitmap too large for the control will be clipped. If the static control contains a single line of text, the text is centered vertically in the client area of the control.

Auch wenn es nicht für mehrzeilige Texte in einem Static-Controls geht, so funktioniert es zumindest für einzeilige Control, was mit Sicherheit die Mehrzahl ist.

Danke CTecS aus dem Deutschen C++ Forum für die Geist-erhellende Anmerkung.

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

I accept that my given data and my IP address is sent to a server in the USA only for the purpose of spam prevention through the Akismet program.More information on Akismet and GDPR.

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.