/** * get the outline level of this row * @return ol - the outline level * @see #getOptionFlags() */ public short getOutlineLevel() { return (short)outlineLevel.getValue(field_7_option_flags); }
SysIndexProcedure(int mask) { this.mask = new BitField(mask); } }
private void setDefaults() { // Set modification flags to 1: by default options are not modified formatting_options = modificationBits.setValue(formatting_options, -1); // Set formatting block flags to 0 (no formatting blocks) formatting_options = fmtBlockBits.setValue(formatting_options, 0); formatting_options = undocumented.clear(formatting_options); formatting_not_used = (short)0x8002; // Excel seems to write this value, but it doesn't seem to care what it reads _fontFormatting = null; _borderFormatting = null; _patternFormatting = null; }
/** * Set a boolean BitField * * @param holder the int data containing the bits we're interested * in * @param flag indicating whether to set or clear the bits * * @return the value of holder with the specified bits set or * cleared */ public int setBoolean(final int holder, final boolean flag) { return flag ? set(holder) : clear(holder); }
/** * Set a boolean BitField * * @param holder the short data containing the bits we're * interested in * @param flag indicating whether to set or clear the bits * * @return the value of holder with the specified bits set or * cleared */ public short setShortBoolean(final short holder, final boolean flag) { return flag ? setShort(holder) : clearShort(holder); }
/** * get the palette index for the right border color * * * @return border - palette index * @see #getPaletteOptions() */ public short getRightBorderPaletteIdx() { return _right_border_palette_idx .getShortValue(field_7_palette_options); }
/** * bit that specifies whether any cell in the row has a thick top border, or any * cell in the row directly above the current row has a thick bottom border. * @param f has thick top border */ public void setTopBorder(boolean f) { field_8_option_flags = topBorder.setBoolean(field_8_option_flags, f); }
/** * swap foreground and background colours when data is negative * @return the invert field value. */ public boolean isInvert() { return invert.isSet(field_4_formatFlags); } }
/** * Set the bits. * * @param holder the byte data containing the bits we're * interested in * * @return the value of holder with the specified bits set to 1 */ public byte setByte(final byte holder) { return ( byte ) set(holder); }
public void getGrammarError(Boolean grammarError) { if (grammarError == null) { pp10extMask = (getPP10RunId() == -1) ? -1 : grammarErrorFld.clear(pp10extMask); } else { pp10extMask = grammarErrorFld.set(pp10extMask); } // if both parameters are invalid, remove the extension mask mask = pp10extFld.setBoolean(mask, pp10extMask != -1); } }
/** * @param pp10RunId an identifier for a character run that contains StyleTextProp11 data, -1 to unset */ public void setPP10RunId(int pp10RunId) { if (pp10RunId == -1) { pp10extMask = (getGrammarError() == null) ? -1 : pp10runidFld.clear(pp10extMask); } else { pp10extMask = pp10runidFld.setValue(pp10extMask, pp10RunId); } // if both parameters are invalid, remove the extension mask mask = pp10extFld.setBoolean(mask, pp10extMask != -1); }
/** * Obtain the value for the specified BitField, unshifted * * @param holder the short data containing the bits we're * interested in * * @return the selected bits */ public short getShortRawValue(final short holder) { return ( short ) getRawValue(holder); }
/** * Clear the bits. * * @param holder the short data containing the bits we're * interested in * * @return the value of holder with the specified bits cleared * (set to 0) */ public short clearShort(final short holder) { return ( short ) clear(holder); }
public void clearFormatting() { field_4_format_runs = null; field_2_optionflags = richText.clearByte(field_2_optionflags); }
/** * @param spellInfo Spelling status of this text. null if not defined. */ public void setSpellInfo(SpellInfoEnum spellInfo) { this.spellInfo = (spellInfo == null) ? -1 : (short)spellInfo.bitField.set(0); mask = spellFld.setBoolean(mask, spellInfo != null); }
/** * Set a boolean BitField * * @param holder the byte data containing the bits we're * interested in * @param flag indicating whether to set or clear the bits * * @return the value of holder with the specified bits set or * cleared */ public byte setByteBoolean(final byte holder, final boolean flag) { return flag ? setByte(holder) : clearByte(holder); } } // end public class BitField
/** * Set a boolean BitField * * @param holder the short data containing the bits we're * interested in * @param flag indicating whether to set or clear the bits * * @return the value of holder with the specified bits set or * cleared */ public short setShortBoolean(final short holder, final boolean flag) { return flag ? setShort(holder) : clearShort(holder); }
/** * Not sure what this is for (maybe fill lines?) 1 = down, 2 = up, 3 = both, 0 for none.. * * * @return diag - whatever it is that this is. * @see #getPaletteOptions() */ public short getDiag() { return _diag.getShortValue(field_7_palette_options); }
/** * Is the sheet hidden? Different from very hidden * * @param hidden {@code true} if hidden */ public void setHidden(boolean hidden) { field_2_option_flags = hiddenFlag.setBoolean(field_2_option_flags, hidden); }