How to draw borders for crosspuzzle to a StringGrid

How to draw borders for crosspuzzle to a StringGrid

Post by KH » Sat, 05 Jul 2003 16:26:14



Hello,
I am attemting to make a crosspuzzle software, and i thought of how i do it
and StringGrid component seems to bbe the best for that.
Can anyone tell how to draw on the stringgrid only those borderlines that
will be needed for crosspuzzle and how to put the letter on the "box".

Thanks, and sorry my poor english

 
 
 

How to draw borders for crosspuzzle to a StringGrid

Post by johnni » Sat, 05 Jul 2003 19:00:22



> Hello,
> I am attemting to make a crosspuzzle software, and i thought of how i
> do it and StringGrid component seems to bbe the best for that.
> Can anyone tell how to draw on the stringgrid only those borderlines
> that will be needed for crosspuzzle and how to put the letter on the
> "box".

> Thanks, and sorry my poor english

I do not understand what exactly you are thinking from what
I can understand since you use a stringgrid then every cell
in the grid will be occupied by one letter only and not by
a word if a cell doesn't have a letter to be inserted keyed
in etc then it must have a collor of black or something other
than white.

if this is not what you are saying then please explain what
you want to happen and why.

regards
johnnie.

 
 
 

1. draw into a stringGrid Cell

Hi to all
            does any one know what's the best way to draw int a cell of a
string Grid using canvas?

i tried this code but it semms to have some bugs

void __fastcall TForm1::GridDrawCell(TObject *Sender, int ACol, int ARow,
      TRect &Rect, TGridDrawState State)
{

  // push
  TFont *OldFont = new TFont();
  OldFont->Assign(Grid->Canvas->Font);
  TBrush *OldBrush = new TBrush();
  OldBrush->Assign(Grid->Canvas->Brush);

  if((ACol>0)&&(ARow>0))
  {
      Grid->Canvas->Brush->Color = clWhite;
      Grid->Canvas->Brush->Style = bsSolid;
      Grid->Canvas->FillRect(Rect);
  }

  Grid->Canvas->Brush->Style = bsClear;
  Grid->Canvas->Font->Assign(Label1->Font);
  Grid->Canvas->TextOut(Rect.left, Rect.top, "3");

  Grid->Canvas->Font->Assign(OldFont);
  Grid->Canvas->TextOut(Rect.left, Rect.top, Grid->Cells[ARow][ACol]);

  Grid->Canvas->Brush->Assign(OldBrush);

thanks

Teo

2. save to stream

3. Pb to draw combobox into stringgrid.

4. Changing colors

5. How to center a figure, and how to draw a border, or outline of box

6. PSP8 - Paint/Fill with transparent color

7. PS7 using Pen Tool to draw around a border

8. TIFF(JPEG) to IOCA conversions

9. Border like Corel Draw 7.0

10. Drawing Borders while Filling Polygons.

11. ?? drawing borders ??

12. Draw Triangles with Borders

13. Drawing a Border around a custom shaped window