change bool to enum : KUrl
hausmann at kde.org
Tue May 2 06:37:24 BST 2006
On Tuesday 02 May 2006 07:09, Olivier Goffart wrote:
> Le Mardi 2 Mai 2006 01:38, Matt Rogers a écrit :
> > some of the enum names could be better. I would change the following to
> > provide better naming:
> > CleanDirSeparator -> SimplifyDirSeparators (CleanPathOption)
> > AppendTrailingSlashToResult -> AppendTrailingSlash (DirectoryOption enum)
> ok, i'll change that, thanks
For the opposite of SimplifyDirSeparators I would go for the plural there as
Although I'm tempted to say Keep is better than Leave since that's the term
commonly used in Qt: QStringList::KeepEmptyParts, Qt::KeepAspectRatio,
For EncodedPathAndQueryOption I suggest to make the enum complete by adding
the default value. Perhaps as PermitEmptyPath and AvoidEmptyPath.
Also for QueryItemsOption I think LowerCaseKeys is a better name than
CaseInsensitiveKeys, since lower casing is exactly what the option does,
while with CaseInsensitiveKeys one might wonder if it adds each key twice in
the map, once upper and once lowercase. Lower case is also used in the
documentation of the option.
For DirectoryOption I suggest to also add IgnoreTrailingSlash as (default)
To avoid the clash with EqualsOption an alternative there would perhaps be
CompareWithoutTrailingSlash and CompareWithoutFragment.
> > IgnoreFragment -> IgnoreHtml (EqualsOption enum)
> I'm not sure this is better.
I agree with IgnoreFragment, since fragment an already established and
documented term in Q/KUrl.
More information about the kde-core-devel