FET - edit & print

Started by g.theodoroy, February 22, 2025, 09:56:17 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

g.theodoroy

#45
Thanks. I checked it.


Added fuctionality:


If we open a fet file without ConstraintActivityPreferredStartingTimes ( not locked file )

all cards are placed in warehouse.



There are two drawbacks i want to solve:

  • the saved fet (xml) file is not well formatted ( no new lines at nodes i added)
  • session memory runs out if we keep changing table ...


g.theodoroy

#46
Fixed memory full.

When memory gets full we remove old entries and add new ones

We keep in session only 35 instances of table.

That means we remember only the last 35 moves of cards

Liviu Lalescu

Oh, I see... for each Undo/Redo operation you need to keep the whole table. We kind of do this also in FET History - we keep each state archived with zlib (via Qt qCompress), because in FET it was impossible to only remember the operation and then undo it.

g.theodoroy


g.theodoroy

Format of downloaded fet file almost fixed !

It's better now ...


Liviu Lalescu

#50
Thank you!

Interesting idea to add Undo states until memory full, then remove old states. What size of memory do you consider full?

Added: I saw two typos in your file: ecxeption, and wont -> exception, won't.

g.theodoroy

#51
According to this site

http://dev-test.nemikor.com/web-storage/support-test/

Same value (Firefox, Chrome, Opera in my Manjaro linux pc) for
  • sessionStorage: limited to 5101 k characters
  • localStorage: limited to 5101 k characters



I decided not to set a hardcoded number ( for example 35 ) because the size of table instance depends on number of teachers and subjects. So for every case a (e.g. 35) number that is OK for me and my data might be NOT OK for other users.


Finally we sacrifice the exact "table entry" that raises the exception of full memory to set the count limit dynamically.

This exception does not affect the moving of cards but stops saving the latest data. We prefer to keep latest data than the previous.

Liviu Lalescu


g.theodoroy

Format of downloaded fet file fixed.

Made small modifications on how day and hour is displayed in table header.


I have a feeling that it tends to be complete.

Probably it will need modifications for "problems" that will show up from the real use of it.

Liviu Lalescu

Good!

I tried it. I have an older question: in the attached screenshot, what are the students sets names in the bottom of the page?

g.theodoroy

#55
In my school we have 5 Student Groups : A1, B1, B2, ΓΠ, ΓΜ.

In some subjects ΓΠ and ΓΜ combine to one group "ΓΠ ΓΜ"

The "Greek high schools logic" is that all Groups should have activities every day for all hours of schedule. No gaps between them.

So when cards are moved we check every column if all groups have activities. If a group has no activity appears to the table footer as "group with no activity" in the bottom of the page.

In uploaded picture this makes sense. For every card (single or double) in warehouse there is a student group in bottom of table to show the missing place. At the same time cell at the table header with hour names becomes grey and on mouse over displays this data in whiteboard (at top center). This data is used to decide which cell should be green (and say "here is the gap")

I need to mention that in the uploaded picture group Α1 and ΓΠ appear twice because they have two teachers. They move together. Actually they are only one activity.



Now, in your picture, where does not apply the "Greek high schools logic" things become messy.

I think i should hide the footer and use a toggle button to show it when user wishes.


We must have in mind that "FET-edit+print" cannot follow the complexity of FET. It is impossible!!!
 

Liviu Lalescu

I think I understand (I am not sure if I understand everything perfectly).

Note: When I load my file, initially there are no students sets at the bottom. Is this a bug?

Oh, don't worry, you did a good work!

g.theodoroy

No.

This function triggers after card move.

Liviu Lalescu


g.theodoroy

If we wish we can trigger it also after table creation