Exemple #1
0
 internal void HighlightCells(SolveInfo solveInfo)
 {
     HighlightedCells.Clear();
     foreach (RuleFinding action in solveInfo.Actions)
     {
         UICell uiCell = UICellFromCell(action.Cell);
         uiCell.Highlight(action.CellRole, action.PencilmarkDataList);
         HighlightedCells.Add(uiCell);
     }
 }
Exemple #2
0
        private UICell CreateUICell(Cell cell, int cellWidth)
        {
            int col = cell.ColIndex;
            int row = cell.RowIndex;
            int x   = 1 + (col * CellWidth) + (1 + col) * ThinGapSize +
                      (1 + col / Board.BlockDimension) * ThickGapIncrement;

            int y = 1 + (row * CellWidth) + (1 + row) * ThinGapSize +
                    (1 + row / Board.BlockDimension) * ThickGapIncrement;

            UICell returnValue = new UICell(cell, cellWidth);

            returnValue.Location = new Point(x, y);
            return(returnValue);
        }