This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """Script standalone "Nou V4" - text negru clar pe alb, din fotografii de pagini | |
| neclare (defocalizate, hartie sepia, umbra puternica) SAU din alb-negru prost facut. | |
| Ce aduce V4 peste V3 | |
| ==================== | |
| A. DECONVOLUTIE RICHARDSON-LUCY <-- castigul principal | |
| Pozele nu sunt doar intunecate, sunt DEFOCALIZATE: fiecare punct de cerneala | |
| e imprastiat pe un disc de cativa pixeli. De aceea barele lui "=" se lipesc | |
| intre ele si capetele de cuvant se pierd. Deconvolutia inverseaza matematic |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """Script standalone "Nou V3" - text negru curat pe alb, din fotografii de pagini | |
| degradate (hartie sepia, umbra puternica, text sters) SAU din alb-negru prost facut. | |
| De ce e mai bun decat "Nou V2": | |
| 1. NORMALIZARE PE CANALE, NU PE GRI | |
| Hartia veche e maro: reflecta mult rosu si putin albastru. Cerneala e neagra | |
| in toate canalele. Raportul cerneala/hartie e deci mult mai bun pe canale | |
| separate decat pe gri. Se normalizeaza fiecare canal cu propriul fundal si | |
| se ia minimul -> contrast maxim. (Pe gri, semnele "=" din formulele sterse |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from __future__ import annotations | |
| import argparse | |
| import configparser | |
| import os | |
| import re | |
| import shutil | |
| import sqlite3 | |
| import sys | |
| import tempfile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Problema | |
| Format Painter și butoanele de aliniere nu mergeau constant fiindcă uneori textul din pagină nu mai era într-un paragraf real (`<p>`), ci rămânea ca text/span direct în `.page`, mai ales după paste sau editări. Atunci `getBlock()` / `blocksInSelection()` nu găseau corect paragraful, deci Justify sau Format Painter nu aveau o țintă bună. | |
| Rezolvarea ta | |
| Ai introdus normalizarea structurii înainte de comenzi: | |
| `ensureBlockStructure()` caută “orfani” în pagină: text direct sau elemente inline direct în `.page`. Dacă le găsește, le înfășoară automat într-un `<p>`, păstrând selecția prin offset-uri de caractere. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """Sortează descrescător, după dată, blocurile de articole din categorii. | |
| Sunt procesate toate fișierele ``.html`` din INPUT_FOLDER care conțin | |
| delimitatorii ``<!-- ARTICOL START -->`` și ``<!-- ARTICOL FINAL -->``. | |
| Prin urmare este inclus și ``index.html`` dacă are aceeași structură. | |
| """ | |
| from __future__ import annotations | |
| import re |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Corecturi gramaticale si ligvistice in limba romana facute pe site-ul https://neculaifantanaru.com | |
| Completeaza *: | |
| Povestea pe care o creezi poate să prindă contur într-o imagine de tipul "chemare la viață", doar dacă ea continuă ideea *. | |
| Cea mai potrivită completare aici mi se pare: | |
| Povestea pe care o creezi poate să prindă contur într-o imagine de tipul „chemare la viață”, doar dacă ea continuă ideea întrupării unei noțiuni într-un personaj viu. | |
| Se leagă foarte bine de fragment: | |
| „Dintr-o noțiune, Ignat devine un personaj viu.” |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Problema. In fiecare html, in sectiunea dintre <!-- SASA-1 --> si <!-- SASA-2 --> am taguri de felul acesta: | |
| <!-- SASA-1 --> | |
| <p class="text_obisnuit2"><em>Fiecare decizie atent cântărită recalibrează traiectoria viziunii tale, creând o nouă ordine a evenimentelor. | |
| </em></p> | |
| <p class="text_obisnuit2"><em>Fiecare decizie atent cântărită recalibrează traiectoria viziunii tale, creând o nouă ordine a evenimentelor. | |
| </em></p> | |
| <!-- SASA-2 --> | |
| ce observi aici este ca finalul tagurilor respectiv </em></p> sau doar </p> trec pe linia urmatoarea in loc sa fie la final de parafrag. De exemplu, in loc de: | |
| <p class="text_obisnuit2"><em>Fiecare decizie atent cântărită recalibrează traiectoria viziunii tale, creând o nouă ordine a evenimentelor. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| GENERIC FORMULAS | |
| ------------------ | |
| Lista Generic Regex: | |
| (?:\G(?!\A)|^.*?(?:BSR))(?:(?!ESR).)*?\K(?:FR) / REPLACE RR | |
| (?:.*?BSR|\G).*?FR\K(.*?)(?=ESR.*?ESR) | |
| (?-si:BSR|(?!\A)\G)(?s-i:(?!ESR).)*?\KFR |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """Audit category pages for the English Leadership website. Read-only.""" | |
| from __future__ import annotations | |
| import argparse | |
| import html | |
| import re | |
| import sys | |
| from collections import Counter | |
| from pathlib import Path |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """Find, add, move, and remove English category summaries after confirmation.""" | |
| from __future__ import annotations | |
| import argparse | |
| import re | |
| import sys | |
| import tkinter as tk | |
| from dataclasses import dataclass | |
| from pathlib import Path |
NewerOlder