Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

`stdWindow` - Improvements

Abierto
#86 3 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
35/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
visualbasic
Área
desktop

Línea de trabajo

Start by locating the stdWindow implementation and review the existing owner, menu-bar, and icon behavior described in the issue. Investigate the taskbar-visibility requirement using the linked reference and provided Windows API example; done means the remaining taskbar behavior is implemented and verified for the relevant window.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement lib-stdWindow

Tracker

  • Set window owner
  • Show menu bar buttons
  • Set icon of window
  • Set taskbar visibility

Change window owner

SetWindowLongPtr(GWL_HWNDPARENT, hwnd) can be used to change the owner of a window. If SetWindowLongPtr(GWL_HWNDPARENT,0) is used the owner is affectively removed, and the window is treated as it's own "top level application" in a sense. Where as SetWindowLongPtr(GWL_HWNDPARENT, Application.hwnd) will make the window only appear when Application is also visible.

Show menu bar buttons

Example:

Call SetWindowLong(hform, GWL_STYLE, existing Or WS_MINIMIZEBOX)
Call DrawMenuBar(hform)

Set icon of window

hIcon = Form.Image1.Picture.Handle
Call SendMessage(hwnd, WM_SETICON, ICON_SMALL, ByVal hIcon)
Call SendMessage(hwnd, WM_SETICON, ICON_BIG, ByVal hIcon)

Enable addition and removal of window from TaskBar maybe more relevant for stdCOM...

See https://www.mrexcel.com/board/threads/display-userform-in-taskbar-with-custom-icon-and-hide-excel-mimicking-a-standalone-application.1123368/page-2

    Call CLSIDFromString(StrPtr(IID_PropertyStore), tIID)
    If SHGetPropertyStoreForWindow(hform, tIID, pPstore) = S_OK Then
        Call CLSIDFromString(StrPtr(CLSID_TASKLIST), tClsID)
        Call CLSIDFromString(StrPtr(IID_TASKLIST3), tIID)
        If CoCreateInstance(tClsID, 0, CLSCTX_INPROC_SERVER, tIID, pTBarList) = S_OK Then
            SetProp Application.hwnd, "pTBarList", pTBarList
            Call vtblCall(pTBarList, ITASKLIST3_HrInit, vbLong, CC_STDCALL) 'HrInit Method
            Call vtblCall(pTBarList, ITASKLIST3_DeleteTab, vbLong, CC_STDCALL, hform) 'DeleteTab Method
            Call vtblCall(pTBarList, ITASKLIST3_AddTab, vbLong, CC_STDCALL, hform) 'AddTab Method
            Call vtblCall(pTBarList, ITASKLIST3_ActivateTab, vbLong, CC_STDCALL, hform) 'ActivateTab Method
            If Len(ThumbnailTooltip) Then
                Call vtblCall(pTBarList, ITASKLIST3_SetThumbnailTooltip, vbLong, CC_STDCALL, hform, StrPtr(ThumbnailTooltip)) 'ActivateTab Method
            End If
        End If
    End If
Lenguaje dominante
VBA
Estrellas
413
Forks
70
Merge medio
16 h 10 min
PR fusionados (30 d)
3

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de sancarn/stdVBA

Todos los issues de sancarn/stdVBA

Issues similares

Más issues de Desktop Dev

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.