Here you can find the source of isRectangularSelection(JComponent c)
public static boolean isRectangularSelection(JComponent c)
//package com.java2s; /*//from w w w. j av a2s . co m * Copyright (c) 2012 Sam Harwell, Tunnel Vision Laboratories LLC * All rights reserved. * * The source code of this document is proprietary work, and is not licensed for * distribution. For information about licensing, contact Sam Harwell at: * sam@tunnelvisionlabs.com */ import javax.swing.JComponent; public class Main { /** Boolean property defining whether selection is being rectangular in a particular text component. */ private static final String RECTANGULAR_SELECTION_PROPERTY = "rectangular-selection"; public static boolean isRectangularSelection(JComponent c) { return Boolean.TRUE.equals(c.getClientProperty(RECTANGULAR_SELECTION_PROPERTY)); } }