MarkdownHelpViewer icon indicating copy to clipboard operation
MarkdownHelpViewer copied to clipboard

memory overflow

Open usystem opened this issue 7 months ago • 15 comments

I compiled the project — it runs and displays .md files, but when I click the About and Settings buttons, there is a memory overflow .

Originally, when launching the .exe, an exception was thrown immediately until I added Russian localization . I think that by default, during settings load, it should use the English language , since it’s available in all installations.

I looked at the code for the "About" button. Here's what I saw: instead of using CreateForm, there's a ShowModal call and a messy piece of code searching for the form in Screen.Forms (even though the form is unloaded from memory when closed), and other unnecessary logic — that's why it doesn't work properly.

I tried it in Delphi 12.2 (both 32-bit and 64-bit versions).

In short, I already have the Russian localization , and I can send it to you if you want.

As for the memory overflow issue , I'm not sure how to fix it yet — could you please suggest where to look or what to check ?

usystem avatar May 09 '25 12:05 usystem

Interesting things: Can you provide me the Exception message at launch when the Russian Localization is not present? Then, please send me the Russian localization so i can add to the project... Try also to install the "pre-built" version using the Setup, so you can see if the overflow it's a build issue (using debug profile) or it's present also in the pre-built version...

carloBarazzetta avatar May 09 '25 13:05 carloBarazzetta

Image its when run prog from official distr.

usystem avatar May 09 '25 14:05 usystem

And when you build the app with the debug (and 64 bit), the same exception is raised? Can you give me the call-stack or is an immediate error, raised before Application.Run ?

carloBarazzetta avatar May 09 '25 14:05 carloBarazzetta

Image and then

Image

usystem avatar May 09 '25 14:05 usystem

I sent RU folder to you email

usystem avatar May 09 '25 15:05 usystem

Thank you very much... To fix the error I need to bypass the exception if the language folder is not present and continue with english version. Thak you for your test ;-)

carloBarazzetta avatar May 09 '25 16:05 carloBarazzetta

I hope you enjoy using MarkdownHelpViewe! Have you tried MarkDownText Editor too?

carloBarazzetta avatar May 09 '25 16:05 carloBarazzetta

I fixed the Russian localization. Now everything works fine. There were some errors in it. Thank you for the great program.

сб, 10 мая 2025 г. в 00:22, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2867148601

Thank you very much... To fix the error I need to bypass the exception if the language folder is not present and continue with english version. Thak you for your test ;-)

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2867148601, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63ABFDDZHQRADTOXKAL25TI5JAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQNRXGE2DQNRQGE . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 09 '25 16:05 usystem

Can you send me your changes of CBMultiLanguage.pas for Russian language support ?

carloBarazzetta avatar May 10 '25 13:05 carloBarazzetta

Yes, sure

сб, 10 мая 2025 г. в 21:06, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2868839417

Can you send me your changes of CBMultiLanguage.pas for Russian language support ?

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2868839417, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63DJYBPOFSSIXMFGF4T25X2UJAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQNRYHAZTSNBRG4 . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 10 '25 13:05 usystem

I recommend increasing the width of the buttons in the ToolBar on the main form:

procedure TMainForm.FormShow(Sender: TObject);
begin
  UpdateWindowPos;
  btAbout.Width := 95;
end;

However, after changing the settings, the width resets — need to adjust it somewhere else as well. Also, set the width of ShowDialectSelectionCheckBox in MDHelpView.SettingsForm to 330.

Have a great evening!

сб, 10 мая 2025 г. в 21:06, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2868839417

Can you send me your changes of CBMultiLanguage.pas for Russian language support ?

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2868839417, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63DJYBPOFSSIXMFGF4T25X2UJAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQNRYHAZTSNBRG4 . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 10 '25 13:05 usystem

I have not received your CBMultiLanguage.pas file yet...

carloBarazzetta avatar May 10 '25 16:05 carloBarazzetta

вс, 11 мая 2025 г. в 00:49, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2869011843

I have not received your CBMultiLanguage.pas file yet...

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2869011843, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63EUCNGZWBVRPBZ2LVT25YU2HAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQNRZGAYTCOBUGM . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 10 '25 21:05 usystem

https://drive.google.com/file/d/1UBJzexhDKs1-vCBfAOGgd_so4g66yWBd/view?usp=sharing

вс, 11 мая 2025 г. в 00:49, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2869011843

I have not received your CBMultiLanguage.pas file yet...

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2869011843, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63EUCNGZWBVRPBZ2LVT25YU2HAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQNRZGAYTCOBUGM . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 10 '25 21:05 usystem

https://drive.google.com/file/d/1UBJzexhDKs1-vCBfAOGgd_so4g66yWBd/view?usp=sharing

-- С уважением Рыболовлев Юрий.

usystem avatar May 12 '25 00:05 usystem

I added colored Emoji, looks great! If you want I'll send you the code (rendered on Skia)

Below is an example in THTMLViewer

[image: изображение.png]

-- С уважением Рыболовлев Юрий.

usystem avatar May 22 '25 12:05 usystem

Any feature is welcome, please send me a zip of the code, or make a pull-request... Please add a new issue explaining the feature... because this issue is closed. Thanks.

carloBarazzetta avatar May 22 '25 19:05 carloBarazzetta

https://drive.google.com/file/d/1dQCFKIVujKbL8Cl39q6yplj44imtDgxA/view?usp=sharing

пт, 23 мая 2025 г. в 03:25, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2902319004

Any feature is welcome, please send me a zip of the code, or make a pull-request...

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2902319004, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63FD66YTYJ3CTEUGUUD27YQDRAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSMBSGMYTSMBQGQ . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 24 '25 14:05 usystem

I'm using your russian translation files but with my codepage I cannot read the correct values... Please attach here another copy of your files, because I've overwrite them and lost .rar (sorry)...

carloBarazzetta avatar May 28 '25 17:05 carloBarazzetta

https://drive.google.com/file/d/1tAATWB4uetDzGNKjsDZo1iXq2UWA_v_K/view?usp=sharing RU - tested

чт, 29 мая 2025 г. в 01:24, Carlo Barazzetta @.***>:

carloBarazzetta left a comment (EtheaDev/MarkdownHelpViewer#14) https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2917084095

I'm using your russian translation files but with my codepage I cannot read the correct values... Please attach here another copy of your files, because I've overwrite them and lost .rar (sorry)...

— Reply to this email directly, view it on GitHub https://github.com/EtheaDev/MarkdownHelpViewer/issues/14#issuecomment-2917084095, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABCS63CNAPJDQQN5BIJVS733AXWONAVCNFSM6AAAAAB4Y7VEDKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSMJXGA4DIMBZGU . You are receiving this because you authored the thread.Message ID: @.***>

-- С уважением Рыболовлев Юрий.

usystem avatar May 29 '25 02:05 usystem