Issue 42965 - The number of 'Numbering type' dialog tab is fixed/hardcoded to 8
Summary: The number of 'Numbering type' dialog tab is fixed/hardcoded to 8
Status: CLOSED FIXED
Alias: None
Product: Internationalization
Classification: Code
Component: code (show other issues)
Version: OOo 1.1.3
Hardware: PC All
: P3 Trivial with 1 vote (vote)
Target Milestone: ---
Assignee: stefan.baltzer
QA Contact: issues@l10n
URL:
Keywords:
Depends on:
Blocks: 41707 43767 54746
  Show dependency tree
 
Reported: 2005-02-17 07:30 UTC by samphan
Modified: 2013-08-07 15:03 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Proposed patch to fix this issue - allow any number of numbering type, display only 8 items but scrollable (1.28 KB, patch)
2005-05-18 15:19 UTC, samphan
no flags Details | Diff
New patch - show vertical scrollbar only when there're more than 8 items (1.31 KB, patch)
2005-05-19 02:37 UTC, samphan
no flags Details | Diff
extend ooo numberingtype samphan's patch (1.51 KB, patch)
2005-06-07 07:32 UTC, hin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description samphan 2005-02-17 07:30:15 UTC
The numbering types (which show up in 'Numbering type' tab on 'Format->Bullets
and Numbering' dialog) for each locale can be defined in the locale's XML file,
e.g. for Thai it is th_TH.xml. Thai localization keeps the existing 8 numbering
types and adds another 4. However the 'Numbering types' tab only shows 8, the
other 4 couldn't be seen/selected. And the dialog tab won't scroll when there're
more numbering type than 8.
Comment 1 samphan 2005-02-17 07:30:52 UTC
The problem is that the number 8 is hard-coded in svx/inc/numpages.hxx
(NUM_VALUSET_COUNT, 680 move the header to svx/source/dialog/numpages.hxx)  and
svx/source/dialog/numpages.cxx. The possible solutions are letting OOo :-
- read the number of numbering types from the locale XML file
- count the number of numbering types in the locale XML file
- has the 'Numbering types' tab that is scrollable, like the 'Graphics' tab 
Comment 2 Martin Hollmichel 2005-05-11 16:08:44 UTC
set target to 2.0.1
Comment 3 samphan 2005-05-18 15:19:09 UTC
Created attachment 26278 [details]
Proposed patch to fix this issue - allow any number of numbering type, display only 8 items but scrollable
Comment 4 samphan 2005-05-18 15:31:01 UTC
I misunderstood the problem. It's not about NUM_VALUSET_COUNT in
numpages.hxx/cxx. It is about the number 8 hardcoded as maximum number of
entries in SvxNumValueSet::SvxNumberingSettings and
SvxNumValueSet::SetOutlineNumberingSettings.

That's because 8 items is about the right size to legibly display
numbering/outline types in the dialog tabs. My change is that the dialog tabs
still display 8 (4x2) items at a time but use vertical scrollbar to see more
than 8. So I lift the maximum of numbering/outline types out (no maxinum of 8
types now).

The downside of this change is that vertical scrollbar always display even when
there're 8 items. It'd be nice if there's WB_AUTOVSCROLL but there isn't (at
least I don't know).
Comment 5 karl.hong 2005-05-18 19:59:57 UTC
In my opinion, 8 language specific types for a language are enough. 

The reason you want to keep orignal 8 types is that those types are well
accepted by all languages, they are defined in en_US.xml.

Currently,  the language for the numbering types showing under 'Format->Bullets
and Numbering' is set under 'Tool->Options->Language setting->Language'. You
don't want to change this global setting, just in order to get numbering types
for other languages. 

So the solution is to add language box under 'Format->Bullets and Numbering', 
you can change language and get different set of pre-defined numbering type.
Just like sorting and indexing,  you can choose different language sorting
algorithm whithout changing global language setting. Then you don't need to keep
orignal 8 types, since you can get them by selecting en-US, and defined 8
language specific type for your language.
Comment 6 karl.hong 2005-05-18 20:11:20 UTC
.
Comment 7 samphan 2005-05-19 02:35:15 UTC
> Currently,  the language for the numbering types showing under 
>'Format->Bullets and Numbering' is set under 
> 'Tool->Options->Language setting->Language'. 

Yes.

> You don't want to change this global setting, just in order 
> to get numbering types for other languages. 

No. Normally, users of a given language will get the global
'Tools->Options->Language Settings->Languages->Locale setting'
set to their languages already.

> So the solution is to add language box under 
> 'Format->Bullets and Numbering'

That would make the dialog tab too complex for such simple task.
Just like date formats, we add all date formats even ones that
already existed in en-US. So users don't have to switch language
(on Format Cells->Numbers) only to get such date formats.
Comment 8 samphan 2005-05-19 02:37:04 UTC
Created attachment 26286 [details]
New patch - show vertical scrollbar only when there're more than 8 items
Comment 9 jjc 2005-05-19 06:36:08 UTC
Samphan, Karl's point, if I understand correctly, is that if there's a language
box, then we don't need to add all the en_US numbering types, only those of the
en_US numbering types that are commonly used in a Thai language environment.  In
other words th_TH would contain the special Thai types together with those of
the US types that Thais commonly use.  Then a Thai user would only need to
change the language if they want to access a numbering type that is unusual in
Thailand.  That makes sense to me.  The question then arises of which of the
en_US numbering  types are used in Thailand. Now I know that 1, 2, 3,... is very
commonly used in Thailand.  What about the others a/A/i/II?

However, even with the language box, I think a limit of 8 is too small to cover
the numbering types typically used in a particular locale.  The numbering type
is a combination of the separator and the numbering sequence; these are fairly
independent. There are at least 3 kinds of separator that are very commonly
used: "N)", "(N)" and "N.". With a limit of 8, as soon as you have 3 numbering
sequences, you are arbitrarily leaving out numbering types.  For example, in
English, (i) and i) are very commonly used, but are not available in the OOo.

To summarize, I think adding a language box is a good idea, but we still need to
allow for more than 8 numbering types.
Comment 10 hin 2005-06-07 07:31:41 UTC
I have extend patch from samphan's patch to select others Numbering type which
more than 8 type.
Comment 11 hin 2005-06-07 07:32:46 UTC
Created attachment 26965 [details]
extend ooo numberingtype samphan's patch
Comment 12 Martin Hollmichel 2005-08-24 13:00:48 UTC
reassign.
Comment 13 Oliver Specht 2005-08-25 14:41:16 UTC
Patch applied in cws thaiissues to 
svx/source/dialog/numpages.cxx
svx/source/dialog/numpages.hxx
svx/source/dialog/svxbmpnumvalueset.cxx
Comment 14 Oliver Specht 2005-10-31 11:29:59 UTC
Reassigned for verification

re-open issue and reassign to sba@openoffice.org
Comment 15 Oliver Specht 2005-10-31 11:30:10 UTC
reassign to sba@openoffice.org
Comment 16 Oliver Specht 2005-10-31 11:30:16 UTC
reset resolution to FIXED
Comment 17 stefan.baltzer 2005-11-11 16:53:41 UTC
SBA: Verified in CWS thaiissues. Works in general (took some files from CWS
siloch to SEE the fix).
This needs to be re-verified as soon as CWS is integrated in master!
Comment 18 stefan.baltzer 2006-03-14 11:54:25 UTC
SBA: OK in Master. When Thai is set as locale, the Numbering dialog has a
scrollbar so that all Thai numbering styles can be accessed. Closed.