OS.g_object_set (textRenderer, OS.xalign, 1f, 0); OS.gtk_tree_view_column_pack_start (columnHandle, pixbufRenderer, false); OS.gtk_tree_view_column_pack_start (columnHandle, textRenderer, true);
OS.g_object_set (pixbufRenderer, OS.xalign, 1f, 0); OS.gtk_tree_view_column_pack_end (columnHandle, textRenderer, false); OS.gtk_tree_view_column_pack_end (columnHandle, pixbufRenderer, true);
void createRenderers (int /*long*/ columnHandle, int modelIndex, boolean check, int columnStyle) {	OS.gtk_tree_view_column_clear (columnHandle);	if ((style & SWT.CHECK) != 0 && check) {		OS.gtk_tree_view_column_pack_start (columnHandle, checkRenderer, false);		OS.gtk_tree_view_column_add_attribute (columnHandle, checkRenderer, OS.active, CHECKED_COLUMN);		/*		* Feature in GTK. The inconsistent property only exists in GTK 2.2.x.		*/		if (OS.GTK_VERSION >= OS.VERSION (2, 2, 0)) {			OS.gtk_tree_view_column_add_attribute (columnHandle, checkRenderer, OS.inconsistent, GRAYED_COLUMN);		}		/*		* Bug in GTK. GTK renders the background on top of the checkbox.		* This only happens in version 2.2.1 and earlier. The fix is not to set the background.   		*/		if (OS.GTK_VERSION > OS.VERSION (2, 2, 1)) {			OS.gtk_tree_view_column_add_attribute (columnHandle, checkRenderer, OS.cell_background_gdk, BACKGROUND_COLUMN);		}	}	int /*long*/ pixbufRenderer = OS.gtk_cell_renderer_pixbuf_new ();	if (pixbufRenderer == 0) error (SWT.ERROR_NO_HANDLES);	int /*long*/ textRenderer = OS.gtk_cell_renderer_text_new ();	if (textRenderer == 0) error (SWT.ERROR_NO_HANDLES);		/*	* Feature in GTK.  When a tree view column contains only one activatable	* cell renderer such as a toggle renderer, mouse clicks anywhere in a cell	* activate that renderer. The workaround is to set a second  cell renderer	* to be activatable.	*/	if ((style & SWT.CHECK) != 0 && check) {		OS.g_object_set (pixbufRenderer, OS.mode, OS.GTK_CELL_RENDERER_MODE_ACTIVATABLE, 0);	}	/* Set alignment */	if ((columnStyle & SWT.RIGHT) != 0) {		OS.g_object_set (textRenderer, OS.xalign, 1f, 0);		OS.gtk_tree_view_column_pack_start (columnHandle, pixbufRenderer, false);		OS.gtk_tree_view_column_pack_start (columnHandle, textRenderer, true);		OS.gtk_tree_view_column_set_alignment (columnHandle, 1f);	} else if ((columnStyle & SWT.CENTER) != 0) {		OS.g_object_set (textRenderer, OS.xalign, 0.5f, 0);		OS.gtk_tree_view_column_pack_start (columnHandle, pixbufRenderer, false);		OS.gtk_tree_view_column_pack_end (columnHandle, textRenderer, true);		OS.gtk_tree_view_column_set_alignment (columnHandle, 0.5f);	} else {		OS.gtk_tree_view_column_pack_start (columnHandle, pixbufRenderer, false);		OS.gtk_tree_view_column_pack_start (columnHandle, textRenderer, true);		OS.gtk_tree_view_column_set_alignment (columnHandle, 0f);	}	/* Add attributes */	OS.gtk_tree_view_column_add_attribute (columnHandle, pixbufRenderer, OS.pixbuf, modelIndex + CELL_PIXBUF);	/*	 * Bug on GTK. Gtk renders the background on top of the pixbuf.	 * This only happens in version 2.2.1 and earlier. The fix is not to set the background.   	 */	if (OS.GTK_VERSION > OS.VERSION (2, 2, 1)) {		OS.gtk_tree_view_column_add_attribute (columnHandle, pixbufRenderer, OS.cell_background_gdk, BACKGROUND_COLUMN);		OS.gtk_tree_view_column_add_attribute (columnHandle, textRenderer, OS.background_gdk, BACKGROUND_COLUMN);	}	OS.gtk_tree_view_column_add_attribute (columnHandle, textRenderer, OS.text, modelIndex + CELL_TEXT);	OS.gtk_tree_view_column_add_attribute (columnHandle, textRenderer, OS.foreground_gdk, FOREGROUND_COLUMN);	OS.gtk_tree_view_column_add_attribute (columnHandle, textRenderer, OS.font_desc, FONT_COLUMN);		boolean customDraw = firstCustomDraw;	if (columnCount != 0) {		for (int i=0; i<columnCount; i++) {			if (columns [i].handle == columnHandle) {				customDraw = columns [i].customDraw;				break;			}		}	}	if ((style & SWT.VIRTUAL) != 0 || customDraw) {		OS.gtk_tree_view_column_set_cell_data_func (columnHandle, textRenderer, display.textCellDataProc, handle, 0);		OS.gtk_tree_view_column_set_cell_data_func (columnHandle, pixbufRenderer, display.pixbufCellDataProc, handle, 0);	}}