QDoc: Extract shared filename computation into Utilities
Both `Generator` and `TemplateGenerator` independently implement the
same ~70-line algorithm for computing documentation page filenames. When
the `TemplateGenerator` was introduced, this logic was copied rather than
shared. This causes a maintenance burden where any filename fix must be
applied in two places.
The core computation now lives in `Utilities::computeFileBase()`. This
is a pure function that takes callback parameters for prefix/suffix
lookup. Both generators become thin wrappers: navigate to page node,
check cache, delegate to the shared function, cache the result. This
also fixes a latent bug where `TemplateGenerator` incorrectly applied
output prefixes to collection nodes (such as modules), which `Generator`
correctly skips.
Fixes: QTBUG-144119
Change-Id: I2f24259d011ca837b3b66fcf6e07e47a91fe5d4b
Reviewed-by: Topi Reinio <topi.reinio@qt.io>