I have created a drawing area using gtk_drawing_area_new(). Window handle(say drawing_handle) of this widget is extracted using GDK_WINDOW_XID.
Using xwininfo i checked the attributes of drawing_handle window.
Output:
ubuntu@wandboard:~$ xwininfo -id 0x1400007
- Absolute upper-left X: 2
- Absolute upper-left Y: 21
- Relative upper-left X: 0
- Relative upper-left Y: 0
- Width: 1916
- Height: 1011
- Depth: 24
- Visual: 0xc7
- Visual Class: TrueColor
- Border width: 0
- Class: InputOutput
- Colormap: 0x1400002 (not installed)
- Bit Gravity State: NorthWestGravity
- Window Gravity State: NorthWestGravity
- Backing Store State: NotUseful
- Save Under State: no
- Map State: IsViewable
- Override Redirect State: no
- Corners: +2+21 -2+21 -2-48 +2-48
- -geometry 1916x1011+0+0
Colormap shows wrong value and Not Installed. Whereas system default Colormap is 32(0x20). There is some system setting missing where gtk is not able to take the correct colormap. Please suggest how gtk-window gets created and how colormap is assigned.
May be this wrong Colormap is flowing down from main window which is created using api gtk_window_new(). Still i don't find any gtk api to change this value for both of the window.