* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
#include "config.h"
g_type_class_add_private (object_class, sizeof (GtkCellRendererPixbufPrivate));
- _gtk_cell_renderer_class_set_accessible_type (cell_class, GTK_TYPE_IMAGE_CELL_ACCESSIBLE);
+ gtk_cell_renderer_class_set_accessible_type (cell_class, GTK_TYPE_IMAGE_CELL_ACCESSIBLE);
}
static void
gint calc_width;
gint calc_height;
gint xpad, ypad;
+ GtkStyleContext *context;
+
+ context = gtk_widget_get_style_context (widget);
+ gtk_style_context_save (context);
+ gtk_style_context_add_class (context, GTK_STYLE_CLASS_IMAGE);
if (!_gtk_icon_helper_get_is_empty (priv->icon_helper))
_gtk_icon_helper_get_size (priv->icon_helper,
gtk_widget_get_style_context (widget),
&pixbuf_width, &pixbuf_height);
+ gtk_style_context_restore (context);
+
if (priv->pixbuf_expander_open)
{
pixbuf_width = MAX (pixbuf_width, gdk_pixbuf_get_width (priv->pixbuf_expander_open));
state = gtk_cell_renderer_get_state (cell, widget, flags);
gtk_style_context_set_state (context, state);
+ gtk_style_context_add_class (context, GTK_STYLE_CLASS_IMAGE);
g_object_get (cell, "is-expander", &is_expander, NULL);
if (is_expander)