readsoftware / ReadIssues

This is an issue repository for READ. Intended for issues and feature change request that arise during testing and development.
0 stars 0 forks source link

new button "renumber lines" #107

Open andrea103 opened 6 years ago

andrea103 commented 6 years ago

add the function to relabel physical lines (under edit when in modify mode). enter of new line labels for example by: "r: 1-20, v: 1-15" for lines 1 to 20 and 21 to 35 (resulting in r1, r2, … r20, v1, v2, … v15). That is, prefixes for all the following numbers before the next comma are to be separated by colon.

stevewh commented 6 years ago

I would expand on the definition as follows. Commas are used to separate labels or label shorthand (a formula prefix : startnumber - finishnumber). So "r:1-8,9a,9b,10-15,v:1-8 would yield r1,r2,r3,r4,r5,r6,r7,r8,9a,9b,10,11,12,13,14,15,v1,v2,v3,v4,v5,v6,v7,v8 which could also be done as "r1,r2,r3,r4,r5,r6,r7,r8,9a,9b,10,11,12,13,14,15,v1,v2,v3,v4,v5,v6,v7,v8".

each label is applied in physical line order until labels are all used or until there are no more physical lines.

Stephen A White Digital Humanities Software Engineer/Consultant email: stephenawhite57@gmail.com ph: +39 389 093 2269

On Fri, Nov 3, 2017 at 12:27 PM, andrea103 notifications@github.com wrote:

Assigned #871 https://github.com/stevewh/READ/issues/871 to @stevewh https://github.com/stevewh.

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/stevewh/READ/issues/871#event-1324687277, or mute the thread https://github.com/notifications/unsubscribe-auth/ACOHIT_EukoNot5aDhsgC1_0E68KtbB_ks5syvi-gaJpZM4QQ9NG .

andrea103 commented 6 years ago

ok.

IanMcCrabb commented 6 years ago

Possible approach is to enable editing on label field in Properties of Physical line.

image

stevewh commented 6 years ago

Since the sequence (type = TextPhysical) is the container that contains the "PhysicalLine" sequences, it seems this is a good place to store the pattern string for generating the line numbers. I would suggest that when the use indicates to renumber physical lines that we show a dialog for editing the pattern and confirming the renumber. Related to this is that once we renumber the glossary locations get out of sync and would need to be refreshed.

andrea103 commented 6 years ago

Update and summary: Current approach is to add a new button (link) in der properties of "TextPhysical," next to "Components:" (see screenshot)

This would open a free text field where to input the new physical lines label sequence as follows.

Commas are used to separate labels or label shorthand (a formula prefix : startnumber - finishnumber). So "r:1-8,9a,9b,10-15,v:1-8 would yield r1,r2,r3,r4,r5,r6,r7,r8,9a,9b,10,11,12,13,14,15,v1,v2,v3,v4,v5,v6,v7,v8 which could also be done as "r1,r2,r3,r4,r5,r6,r7,r8,9a,9b,10,11,12,13,14,15,v1,v2,v3,v4,v5,v6,v7,v8". Each label is applied in physical line order until labels are all used or until there are no more physical lines (e.g., for very long manuscripts, entering 1-600 could be used, even though there are only 574 physical lines).

In addition to the free text field, there should be three buttons: preview, OK and cancel.

Preview calculates the new numbering and displays for each component next to the current numbering (in bold). OK executes the renumbering and refreshs the display. Cancel removes the UI and leaves the current numbering.

In case of multi-editions: The renumbering will clone any unowned physical line sequences.

renumber_button_a