/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/*
* (C) Copyright IBM Corp. 1998-2003, All Rights Reserved
*
*/
private int graphicCount;
// evaluated in computeVisualBounds
// used everywhere so we'll cache it
private float graphicAdvance;
/**
* Create a new GraphicComponent. start and limit are indices
* into charLtoV and levels. charsLtoV and levels may be adopted.
*/
int[] charsLtoV,
byte[] levels,
int start,
int limit,
throw new IllegalArgumentException("0 or negative length in GraphicComponent");
}
}
}
start = 0;
if (dir == RIGHT_TO_LEFT) {
for (int i=0; i < limit; i++) {
levels[i] = (byte) 1;
}
}
}
else {
throw new IllegalArgumentException("Invalid direction flag");
}
}
/**
* Initialize graphicCount, also charsLtoV and levels arrays.
*/
byte[] levels,
int start,
int limit) {
}
else {
}
}
else {
this.levels = new byte[graphicCount];
}
}
public boolean isSimple() {
return false;
}
throw new InternalError("do not call if isSimple returns false");
}
}
return cm;
}
0, // ss offset
0); // italic angle -- need api for this
}
public float getItalicAngle() {
return 0;
}
if (visualBounds == null) {
}
return bounds;
}
if (graphicCount == 1) {
}
for (int i = 0; i < graphicCount; ++i) {
}
return gp;
}
return baseTx;
}
return decorator.getOutline(this, x, y);
}
for (int i=0; i < graphicCount; i++) {
x += graphicAdvance;
}
}
}
}
public int getNumCharacters() {
return graphicCount;
}
return graphicAdvance * visIndex;
}
return 0;
}
return graphicAdvance;
}
return true;
}
// don't modify their rectangle, just in case they don't copy
return charBounds;
}
// measures characters in context, in logical order
}
return index;
}
// measures characters in context, in logical order
}
float left = 0;
}
public float getAdvance() {
return graphicAdvance * graphicCount;
}
return getLogicalBounds();
}
throw new IllegalArgumentException("Invalid range. start="
}
return this;
}
}
}
/**
* Return the number of justification records this uses.
*/
public int getNumJustificationInfos() {
return 0;
}
/**
* Return GlyphJustificationInfo objects for the characters between
* charStart and charLimit, starting at offset infoStart. Infos
* will be in visual order. All positions between infoStart and
* getNumJustificationInfos will be set. If a position corresponds
* to a character outside the provided range, it is set to null.
*/
public void getJustificationInfos(GlyphJustificationInfo[] infos, int infoStart, int charStart, int charLimit) {
}
/**
* Apply deltas to the data in this component, starting at offset
* deltaStart, and return the new component. There are two floats
* for each justification info, for a total of 2 * getNumJustificationInfos.
* The first delta is the left adjustment, the second is the right
* adjustment.
* <p>
* If flags[0] is true on entry, rejustification is allowed. If
* the new component requires rejustification (ligatures were
* formed or split), flags[0] will be set on exit.
*/
public TextLineComponent applyJustificationDeltas(float[] deltas, int deltaStart, boolean[] flags) {
return this;
}
}