public void delete(int v) {
		// ʾ

		p = root;
		if (p == null) {
			Message.AtLeastOneElement();
			return;
		}

		state = State.delete;
		data = v;
		// δҵԪ
		if (!shortSearch(v)) {
			Message.NoSuchElement(v);
		} else {
			// ֻһ㣬ֱɾ
			if (root.isLeaf)
				root.remove(v);
			else if (root.numOfElements == 1) {
				BTreeNode left = root.children[0];
				BTreeNode right = root.children[1];
				// ڵӽڵΪԪصʱϲڵ
				if (left != null && right != null
						&& left.numOfElements == mid - 1
						&& right.numOfElements == mid - 1) {
					merge(root, 1, left, right);
					root = left;
					Recount();
				}

				deleteUnderRoot(root, v);
				Recount();
			} else {
				System.out.println("ok");
				deleteUnderRoot(root, v);
				Recount();
			}
			state = State.deleted;
			repaint();
			paintAll(getGraphics());
		}
	}