VladislavAntonyuk / vladislavantonyuk.github.io

https://vladislavantonyuk.github.io
2 stars 1 forks source link

Markdown tag Scrollview functionality #86

Closed cghemis closed 8 months ago

cghemis commented 9 months ago

@VladislavAntonyuk there's any trick, using this repo https://github.com/VladislavAntonyuk/MauiSamples/tree/main/MauiMarkdown, to add a scroll view functionality for markdown, because I've try to render a long text and it's not working. Also, I can't place the mauiMarkdown tag into a StackLayout or VerticalStackLayout, it doesn't render. Hence, the only way I was able to add a scroll functionality, but for no reason for a long text it doesn't seems to render it all.

 <ScrollView VerticalScrollBarVisibility="Always">
            <Grid RowDefinitions="*">
            <mauiMarkdown:MarkdownGraphicsView Grid.Row="0"
                                           Text="MyValue"
                                           FontColor="{AppThemeBinding Light=Black,Dark=White}"/>
        </Grid>
 </ScrollView>
VladislavAntonyuk commented 8 months ago

MarkDownView is a GraphicsView, so ScrollView control doesn't have any effect. But you can simulate the behavior using DragInteraction event

VladislavAntonyuk commented 8 months ago

Updated sample app