سلام میخوام صفحه اصلی برنامم دکمه هاش با عکس باشه . اما نمیدونم چرا بهم میرییزه؟ یعنی رو صفحه موبایل خودم خوب هست اما روی تبلت و اینها جمع میشه یا رو گوشی های دیگه سایزش تغییر میکنه. سوالم این هست که ایا دلیلش این هست که باید من چهار سایز عکس درست کنم و توی پوشه های drawble ها بزارم؟ یا مشکل چیز دیگه اس هست.
باید سایز هاشون رو بر اساس وزن بدید
weight
از عدد 10 شروع کنید
مثلا 3 تا دارید به هر کدام 3 بدید
این گزینه را توی <image پیدا نمی کنم. من این کد را نوشتم
<ScrollView> <StackLayout> <StackLayout> <Grid BackgroundColor="White" ColumnSpacing="0" x:Name="gr" HeightRequest="530" > <Grid.RowDefinitions> <RowDefinition Height="496*" /> <RowDefinition Height="504*" /> </Grid.RowDefinitions> <Grid.ColumnDefinitions> <ColumnDefinition Width="607*" /> <ColumnDefinition Width="393*" /> </Grid.ColumnDefinitions> <Grid Grid.Column="0" Grid.Row="0" ColumnSpacing="0" RowSpacing="0" > <cards:CarouselView ItemsSource="{Binding PicAsliList}" SelectedIndex="{Binding TablePictureAsliPosition}" SlideShowDuration="10000" SwipeThresholdTime="20" SelectedItem="{Binding TablePictureAsliCode}" x:Name="crvw" > <cards:CarouselView.ItemTemplate> <DataTemplate> <Grid> <Grid.RowDefinitions> <RowDefinition Height="*"/> <RowDefinition Height="Auto"/> </Grid.RowDefinitions> <ContentView Grid.Row="0" > <Image Source="{Binding TablePictureAslipic}" x:Name="crimg"/> </ContentView> <StackLayout Grid.Row="1" BackgroundColor="#80000000" Padding="12"> <Label TextColor="White" Text="{Binding TablePictureAsliMatn}" FontSize="16" HorizontalOptions="Center" VerticalOptions="CenterAndExpand"/> </StackLayout> </Grid> </DataTemplate> </cards:CarouselView.ItemTemplate> </cards:CarouselView> </Grid> <Grid Grid.Column="1" Grid.Row="0" ColumnSpacing="0" RowSpacing="0" Padding="2" BackgroundColor="White" > <Grid.RowDefinitions> <RowDefinition Height="250*" /> <RowDefinition Height="80*" /> <RowDefinition Height="80*" /> </Grid.RowDefinitions> <Image Grid.Row="0" Source="@Resources/menbar.png" Aspect="Fill" /> <Button Grid.Row="0" Opacity="0" x:Name="sokhanrani" Clicked="sokhanrani_Clicked" /> <Image Grid.Row="1" Source="@Resources/flashcart.png" Aspect="Fill" /> <Button Grid.Row="1" Opacity="0" x:Name="flashcart" Clicked="flashcart_Clicked" /> <Image Grid.Row="2" Source="@Resources/soalat.png" Aspect="Fill" /> <Button Grid.Row="2" Opacity="0" x:Name="soalaat" Clicked="soalaat_Clicked" /> </Grid> <Grid Grid.Row="1" Grid.Column="0" ColumnSpacing="0" RowSpacing="0" BackgroundColor="White"> <Grid.RowDefinitions> <RowDefinition Height="184*" /> <RowDefinition Height="98*" /> <RowDefinition Height="174*" /> </Grid.RowDefinitions> <Image Source="@Resources/tazkare.png" Grid.Row="0" Aspect="Fill" /> <Button Grid.Row="0" Opacity="0" x:Name="tazkare" Clicked="tazkare_Clicked" /> <Image Source="@Resources/amoozeshmadahi.png" Grid.Row="1" Aspect="Fill" /> <Button Grid.Row="1" Opacity="0" x:Name="amoozehsmadahi" Clicked="amoozehsmadahi_Clicked" /> <Image Grid.Row="2" Source="@Resources/hafez.png" Aspect="Fill" /> <Button Grid.Row="2" Opacity="0" x:Name="hafez" Clicked="hafez_Clicked" /> </Grid> <Grid Grid.Row="1" Grid.Column="1" ColumnSpacing="0" RowSpacing="0" BackgroundColor="White"> <Grid.RowDefinitions> <RowDefinition Height="282*" /> <RowDefinition Height="80*" /> <RowDefinition Height="80*" /> </Grid.RowDefinitions> <Image Grid.Row="0" Source="@Resources/madahi.png" Aspect="Fill" /> <Button Grid.Row="0" Opacity="0" x:namem="madahi" Clicked="Button_Clicked" /> <Image Grid.Row="1" Source="@Resources/chakame.png" Aspect="Fill" /> <Button Grid.Row="1" Opacity="0" x:Name="chakame" Clicked="chakame_Clicked" /> <Image Grid.Row="2" Source="@Resources/akhbar.png" Aspect="Fill" /> <Button Grid.Row="2" Opacity="0" x:Name="akhbar" Clicked="akhbar_Clicked" /> </Grid> </Grid> </StackLayout> <StackLayout> <Grid BackgroundColor="White" HeightRequest="230" RowSpacing="0" > <Grid.RowDefinitions> <RowDefinition Height="40*" /> <RowDefinition Height="40*" /> <RowDefinition Height="40*" /> </Grid.RowDefinitions> <Grid Grid.Row="0" BackgroundColor="White"> <Image Grid.Row="0" Source="@Resources/salavati.png" Aspect="Fill" /> <Button Grid.Row="0" Opacity="0" x:Name="salavati" Clicked="salavati_Clicked" /> </Grid> <Grid Grid.Row="1" BackgroundColor="White"> <Grid.ColumnDefinitions> <ColumnDefinition Width="40*" /> <ColumnDefinition Width="40*" /> </Grid.ColumnDefinitions> <Image Grid.Column="0" Source="@Resources/ertebat.png" Aspect="Fill" /> <Button Grid.Column="0" Opacity="0" x:Name="ertebat" Clicked="ertebat_Clicked" /> <Image Grid.Column="1" Source="@Resources/ax.png" Aspect="Fill" /> <Button Grid.Column="1" Opacity="0" x:Name="ax" Clicked="ax_Clicked" /> </Grid> <!--<Grid Grid.Row="2" BackgroundColor="White"> <Grid.ColumnDefinitions> <ColumnDefinition Width="40*" /> <ColumnDefinition Width="40*" /> </Grid.ColumnDefinitions> <Image Grid.Column="0" Source="@Resources/taghche.png" Aspect="Fill" /> <Button Grid.Column="0" Opacity="0" x:Name="taghche" Clicked="taghche_Clicked"/> <Image Grid.Column="1" Source="@Resources/nazr.png" Aspect="Fill" /> <Button Grid.Column="1" Opacity="0" x:Name="nazr" Clicked="nazr_Clicked" /> </Grid>--> </Grid> </StackLayout> </StackLayout> </ScrollView>
هیچ کاربری تا کنون از این پست تشکر نکرده است
با ما تماس بگیرید تا در این مسیر همراهتان باشیم :)