Skip to content

doesn't grab focus with xmonad #87

@mwotton

Description

@mwotton

when i run dmenu, keyboard focus goes straight to the input. with lighthouse, i seem to have to move the mouse to the window.

I tried poking it a bit:

  fprintf(stderr, "trying to set focus\n");
  xcb_void_cookie_t set_focus = xcb_set_input_focus_checked(connection, XCB_INPUT_FOCUS_POINTER_ROOT, window, XCB_CURRENT_TIME);
  fprintf(stderr, "set focus, apparently\n");
  xcb_generic_error_t *error;
  if ((error = xcb_request_check(connection, set_focus))) {
    fprintf(stderr, "Could not set focus: %d. responsetype: %d. minor:%d. major:%d.\n",
            error->error_code, error->response_type, error->minor_code, error->major_code);
    free(error);
    goto cleanup;
  }

but got

Could not set focus: 8. responsetype: 0. minor:0. major:42.

any help in debugging would be appreciated, lighthouse looks like exactly what i'm after (just want to hook it up to https://github.com/mwotton/dustme )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions