boolean IsLink(int x1, int y1, int x2, int y2)
  {
    if (x1 == x2)
    {
      if (X_Link(x1, y1, y2)) {
        LType = LinkType.LineType; return true;
      }
    }
    else if (y1 == y2)
    {
      if (Y_Link(x1, x2, y1)) {
        LType = LinkType.LineType; return true;
      }
    }
    if (OneCornerLink(x1, y1, x2, y2))
    {
      LType = LinkType.OneCornerType;
      return true;
    }

    if (TwoCornerLink(x1, y1, x2, y2))
    {
      LType = LinkType.TwoCornerType;
      return true;
    }
    return false;
  }