1 /*******************************************************************************
2 * Copyright (c) 2007, 2010 Association for Decentralized Information Management
4 * All rights reserved. This program and the accompanying materials
5 * are made available under the terms of the Eclipse Public License v1.0
6 * which accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
10 * VTT Technical Research Centre of Finland - initial API and implementation
11 *******************************************************************************/
12 package org.simantics.scenegraph.g2d;
14 import java.awt.Component;
15 import java.awt.RenderingHints.Key;
16 import java.awt.geom.Rectangle2D;
19 * @author Tuukka Lehtonen
20 * See {@link G2DPDFRenderingHints}
22 public final class G2DRenderingHints {
25 * A rendering hint for storing the boundaries of the control area within a
26 * Graphics2D instance.
28 public static final Key KEY_CONTROL_BOUNDS = new Key(1000) {
30 public boolean isCompatibleValue(Object val) {
31 return val instanceof Rectangle2D;
36 * A rendering hint for storing the root AWT Component on which the scene
37 * graph is rendered within a Graphics2D instance.
39 public static final Key KEY_COMPONENT = new Key(1001) {
41 public boolean isCompatibleValue(Object val) {
42 return val instanceof Component;