可垂直或水平滚动的列表

ScrollView & HorizontalScrollView内部只能有一个直接的子元素,

<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"> <LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"> <Button
android:id="@+id/button_1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Button1"/> <Button
android:id="@+id/button_2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="TEST"
/> <HorizontalScrollView
android:layout_width="wrap_content"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<Button android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Button1TESTTEST"/> <Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="TESTTESTTEST"
/><Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="ButTESTTESTTESTton1"/> <Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="TETESTTESTTESTST"
/>
<Button android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Button1TESTTEST"/> <Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="TESTTESTTEST"
/><Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="ButTESTTESTTESTton1"/> <Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="TETESTTESTTESTST"
/> </LinearLayout> </HorizontalScrollView> </LinearLayout> </ScrollView>

ScrollView & HorizontalScrollView的更多相关文章

  1. Android开发工程师文集-Fragment,适配器,轮播图,ScrollView,Gallery 图片浏览器,Android常用布局样式

    Android开发工程师文集-Fragment,适配器,轮播图,ScrollView,Gallery 图片浏览器,Android常用布局样式 Fragment FragmentManager frag ...

  2. Android ViewPager+HorizontalScrollView实现标题栏滑动(腾讯新闻)

    1) ViewPager提供了左右滑动切换页面的方法,但是它所提供的标题只是无语,估计没有真正的项目会照搬拿过来;并且它只能一页一页滑,我想直接查看最后一页要滑半天; 2) 看了腾讯新闻客户端感觉体验 ...

  3. ScrollView+RadioGroup

    今天要分享一下关于动态添加RadioButton的东西: 要实现的效果就是,这个控件可以左右滑动,里面的按钮都是互斥的,类似RadioButton,我的第一反应就是用ScrollView+RadioG ...

  4. 【Android UI】侧滑栏的使用(HorizontalScrollView控件的使用)

    主要的用到的控件:HorizontalScrollView 主要的功能:把几张图片解析成一张图片,在一个容器中呈现. 布局文件xml side_bar_scollview.xml//显示view的容器 ...

  5. Xamarin. Android实现下拉刷新功能

    PS:发现文章被其他网站或者博客抓取后发表为原创了,给图片加了个水印 下拉刷新功能在安卓和iOS中非常常见,一般实现这样的功能都是直接使用第三方的库,网上能找到很多这样的开源库.然而在Xamarin. ...

  6. ListView上拉加载,下拉刷新 PullToRefresh的使用

    PullToRefresh是一套实现非常好的下拉刷新库,它支持:ListViewExpandableListViewGridViewWebViewScrollViewHorizontalScrollV ...

  7. 【练习】ViewPager标签滑动

    效果图: 布局: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:a ...

  8. 【Android - 进阶】之自定义视图浅析

    1       概述 Android自定义View / ViewGroup的步骤大致如下: 1) 自定义属性: 2) 选择和设置构造方法: 3) 重写onMeasure()方法: 4) 重写onDra ...

  9. Java-Android 之出滚动条和卷轴页面

    <?xml version="1.0" encoding="utf-8"?> <HorizontalScrollView xmlns:andr ...

随机推荐

  1. .Net Core 在Linux服务器下部署程序--(4). 前端ReactWeb应用部署

    确认第二步中的软件已经安装完成 Nodejs前端Web服务器 Zip与UnZip压缩包软禁 nrm前端包源管理器 PM2前端Web程序守护进程 创建部署文件夹 如果已经执行过( 3. 租户平台后端程序 ...

  2. .Net Core 在Linux服务器下部署程序--(3). 部署.net Core程序

    确认第二步中的软件已安装完成 lrzsz文件上传下载软件 zip与unzip压缩包软件 net core 相关软件 确认上述软件安装完成之后,开始部署程序 创建部署文件夹 我的习惯是在usr文件夹下新 ...

  3. Web前端教程3-JavaScript教程

    目录 1. JavaScript介绍 1.1. JS嵌入页面的方式 2. JS基本语法 2.1. 变量类型 2.2. 获取元素方法 2.3. 操作元素属性 2.4. innerHTML的使用 3. J ...

  4. P4013 数字梯形问题 网络流

    题目描述 给定一个由 nn 行数字组成的数字梯形如下图所示. 梯形的第一行有 mm 个数字.从梯形的顶部的 mm 个数字开始,在每个数字处可以沿左下或右下方向移动,形成一条从梯形的顶至底的路径. 分别 ...

  5. Map根据value值进行倒序排列

    public List<Map.Entry<Integer,BigDecimal>> sortByMapValue(HashMap<Integer, BigDecimal ...

  6. SQL insert into select 语句

    遇到权限数据变更的需要批量到别的平台, 在175平台添加一个权限需要, 批量到别的现有平台, 以后的建站, 会把sql放到自动建站里面; 权限的 insert into select 表一: `ous ...

  7. StringUtils工具类常用方法详解

    StringUtils 常用方法 1.isEmpty(String str) 是否为空,空格字符为false2.isNotEmpty(String str) 是否为非空,空格字符为true3.isBl ...

  8. day正则表达式补充

    # 2.正则 # 方法:findall | match | split | sub# a = 10# print(a.__hash__())# def fn():# pass# print(fn.__ ...

  9. 企业移动化?AppCan教你正确的打开方式

    七分选型.三分软件.的确,在过去的企业移动化进程中,由于选型失败导致信息系统实施失败的案例屡见不鲜.而在当今的移动互连和大数据时代,移动化已经是企业必然的选择. 那么,什么是企业移动化呢?怎样才是企业 ...

  10. Springboot + Atomikos + Druid + Mysql 实现JTA分布式事务

    DataSource 配置 package com.cheng.dynamic.config; import java.util.Properties; import javax.sql.DataSo ...