Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add number display for post-pushing #42

Open
tnlin opened this issue Apr 6, 2015 · 2 comments
Open

Add number display for post-pushing #42

tnlin opened this issue Apr 6, 2015 · 2 comments

Comments

@tnlin
Copy link

tnlin commented Apr 6, 2015

Number display for post-pushing is good for user to interact with other user in the same post
Here is a sketch
hope
This function also have been implemented in JPTT & MoPTT (Close Source App)

@kidwm
Copy link
Member

kidwm commented Apr 8, 2015

這應該是提供外掛機制才能做的事。

hwangcc23 added a commit to hwangcc23/pcmanx that referenced this issue Apr 13, 2016
Numbering Post-Push is a good function for discussion in one post.
See the issue pcman-bbs#42(pcman-bbs#42).

1). Add a field PostPushNum in the line structure.
The line structure:
struct{ char[ColsPerPage], char='\0', CTermCharAttr[ColsPerPage, char=0]}
[ ColsPerPage*char + '\0' + ColsPerPage*CTermCharAttr + PostPushNum ]

2). Detect Post-Push lines and numbering them whenever a character is added in the screen buffer of CTermData.

3). Save the number in PostPushNum of Post-Push lines.

4). Draw PostPushNum in CTermView:DrawChar().

5). Fix a bug of buffer overflow in CTermData::InsertChar(). p.s. Though the function is not used now.
hwangcc23 added a commit to hwangcc23/pcmanx that referenced this issue Apr 13, 2016
Numbering Post-Push is a good function for discussion in one post.
See the issue pcman-bbs#42(pcman-bbs#42).

1). Add a field PostPushNum in the line structure.
The line structure:
struct{ char[ColsPerPage], char='\0', CTermCharAttr[ColsPerPage, char=0]}
[ ColsPerPage*char + '\0' + ColsPerPage*CTermCharAttr + PostPushNum ]

2). Detect Post-Push lines and numbering them whenever a character is added in the screen buffer of CTermData.

3). Save the number in PostPushNum of Post-Push lines.

4). Draw PostPushNum in CTermView:DrawChar().

5). Fix a bug of buffer overflow in CTermData::InsertChar(). p.s. Though the function is not used now.
hwangcc23 added a commit to hwangcc23/pcmanx that referenced this issue Apr 13, 2016
Numbering Post-Push is a good function for discussion in one post.
See the issue pcman-bbs#42(pcman-bbs#42).

1). Add a field PostPushNum in the line structure.
The line structure:
struct{ char[ColsPerPage], char='\0', CTermCharAttr[ColsPerPage, char=0]}
[ ColsPerPage*char + '\0' + ColsPerPage*CTermCharAttr + PostPushNum ]

2). Detect Post-Push lines and numbering them whenever a character is added in the screen buffer of CTermData.

3). Save the number in PostPushNum of Post-Push lines.

4). Draw PostPushNum in CTermView:DrawChar().

5). Fix a bug of buffer overflow in CTermData::InsertChar(). p.s. Though the function is not used now.
@hwangcc23
Copy link
Contributor

寶傑哥好,各位鄉民大家好,

小魯覺得給推文編號的這功能很讚,
用清明假期作了一個初版,結果如下圖 (當肛人的推文出現時這功能就很需要 XD),
想把修改先丟出來給大家看看,一起討論下。

作法是在從網路接收到字元後,檢查所在該行是否為推文,
若是推文,則計算樓數,存在 line structure,
等要把該行字元畫出來時,一併畫出幾樓。
不過這樣有一個限制,若使用 page-down/up 一次刷新太多行,就無法算出樓數。(除非一次讀入整篇文章,一次作好計算。或是看看大家有沒有什麼其他建議。)

pcmanx_numbering_push_post

hwangcc23 added a commit to hwangcc23/pcmanx that referenced this issue Apr 18, 2016
Numbering Post-Push is a good function for discussion in one post.
See the issue pcman-bbs#42(pcman-bbs#42).

1). Add a field PostPushNum in the line structure.
The line structure:
struct{ char[ColsPerPage], char='\0', CTermCharAttr[ColsPerPage, char=0]}
[ ColsPerPage*char + '\0' + ColsPerPage*CTermCharAttr + PostPushNum ]

2). Detect Post-Push lines and numbering them whenever a character is added in the screen buffer of CTermData.

3). Save the number in PostPushNum of Post-Push lines.

4). Draw PostPushNum in CTermView:DrawChar().

5). Fix a bug of buffer overflow in CTermData::InsertChar(). p.s. Though the function is not used now.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants