How can we have the answer placed into grid same as what we see in answer dialog (yellow tick mark on the screen shot)?
When added to grid it is broken as per the consonant and associated character (HALANT or VIRAM sign)
Expected letter in grid is : क्षति
whereas Actual letters in grid : क ् ष त ि
This program is probably the best crossword generator I can find. The flaw is it lacks this function: check the length of a word and arrange them compactly so there is not so many empty grids.
To realize that, the solution can be this: from a dictionary of tens of thousands of entries, the program select a word, then select the next word according to the last word's letters, repeat this till end.