View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0011632 | Scribus | Internal | public | 2013-06-25 20:02 | 2014-07-04 13:23 |
| Reporter | Hellstorm | Assigned To | cbradney | ||
| Priority | normal | Severity | feature | Reproducibility | have not tried |
| Status | closed | Resolution | fixed | ||
| Product Version | 1.4.2 | ||||
| Target Version | 1.5.0 | Fixed in Version | 1.5.0svn | ||
| Summary | 0011632: Function to generate Chinese page numbers | ||||
| Description | Hello, Sometimes, Chinese books show the page numbering in Chinese letters, not in arabic ones. Currently, Scribus does only support the automatic page numbering in arabic letters. Well, I tried to do this in C++, but somehow... C++ is to difficult for me as a beginner :D Because I have no way to actually try the function in Scribus itself (compiling Scribus does not really work on my PC), I could only create the function on my pc, but without actually trying it. Also, the function would be so badly programmed that I thought you'd need more time to correct it rather than build it from scratch. But because I didn't want to do nothing, I created it in Python. I know that Scribus is not written in Python, but... Well, anyway, I hope you may implement it in C++. Actually the method is quite easy: Replace every roman digit by the appropriate Chinese one. For example, 123 will become ??? (\u4E00\u4E8C\u4E09). After implementing this, it would then be good if there was a new item in Insert\Character with the name "Chinese page number", which is basically just the ordinary page number converted with this function to a Chinese number. I hope this can be implemented :) Thank you :) | ||||
| Tags | No tags attached. | ||||
| Attached Files | cjknumber.py (469 bytes)
def int_to_cjk(number):
map = {
"0": "\u3007", #〇
"1": "\u4E00", #一
"2": "\u4E8C", #二
"3": "\u4E09", #三
"4": "\u56DB", #四
"5": "\u4E94", #五
"6": "\u516D", #六
"7": "\u4E03", #七
"8": "\u516B", #八
"9": "\u4E5D" #九
}
cjknumber = str(number)
for i in map:
cjknumber = cjknumber.replace(i, map[i])
return cjknumber
| ||||
| Patch | |||||
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2013-06-25 20:02 | Hellstorm | New Issue | |
| 2013-06-25 20:02 | Hellstorm | File Added: cjknumber.py | |
| 2013-06-26 05:49 | christoph_s | Assigned To | => cbradney |
| 2013-06-26 05:49 | christoph_s | Status | new => assigned |
| 2013-06-26 05:49 | christoph_s | Target Version | => 1.5.1 |
| 2013-06-26 19:27 | cbradney | Assigned To | cbradney => |
| 2013-06-26 19:39 | jghali | Status | assigned => new |
| 2014-06-22 20:21 | cbradney | Assigned To | => cbradney |
| 2014-06-22 20:21 | cbradney | Status | new => assigned |
| 2014-06-23 07:52 | cbradney | Status | assigned => resolved |
| 2014-06-23 07:52 | cbradney | Fixed in Version | => 1.5.0svn |
| 2014-06-23 07:52 | cbradney | Resolution | open => fixed |
| 2014-06-25 20:04 | cbradney | Status | resolved => closed |
| 2014-07-04 13:23 | Kunda | Target Version | 1.5.1 => 1.5.0 |