Method

IpuzAcrosticset_source

Declaration [src]

void
ipuz_acrostic_set_source (
  IpuzAcrostic* self,
  const char* source_str
)

Description [src]

Sets the source of the puzzle. Traditionally it is some combination of the author and the title of the work. This is a human-displayable representation.

This string is saved and restored when loading and saving to disk.

If length of source_str differs from the number of clues of self, it can be reconciled by calling ipuz_acrostic_fix_source().

As an example:

ipuz_acrostic_set_source (acrostic, "Persuasion / Jane Austen");
ipuz_acrostic_fix_source (acrostic, IPUZ_ACROSTIC_SYNC_STRING_TO_PUZZLE);

Results in a puzzle with twenty clues. The first letter of the answer of each clue is expected to start with the letter P, then E, then R, etc.

Note

Every letter in the source needs to also be found in the quote for the puzzle to be solveable. This function will not double check that as it can be called independently from ipuz_acrostic_set_quote().

Sets propertyIpuz.Acrostic:source

Parameters

source_str

Type: const char*

The source string of the puzzle.

The data is owned by the caller of the method.
The value is a NUL terminated UTF-8 string.