最近在学习小米便签的开源项目,现在对note编辑界面对应的note_edit.xml做一些注释笔记。
项目地址:https://github.com/MiCode/Notes

界面效果如图:

<?xml version="1.0" encoding="utf-8"?><!-- Copyright (c) 2010-2011, The MiCode Open Source Community (www.micode.net)Licensed under the Apache License, Version 2.0 (the "License");you may not use this file except in compliance with the License.You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, softwaredistributed under the License is distributed on an "AS IS" BASIS,WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.See the License for the specific language governing permissions andlimitations under the License.
--><FrameLayout
    android:layout_width="fill_parent"android:layout_height="fill_parent"android:background="@drawable/list_background"xmlns:android="http://schemas.android.com/apk/res/android"><LinearLayout
        android:layout_width="fill_parent"android:layout_height="fill_parent"android:orientation="vertical">
<!--顶栏代码:当前时间(TextView),闹钟icon(ImageView),提醒时间(TextView),颜色选择按钮(ImageButton)
--><LinearLayout
            android:id="@+id/note_title"android:layout_width="fill_parent"android:layout_height="wrap_content"><TextView
                android:id="@+id/tv_modified_date"android:layout_width="0dip"android:layout_height="wrap_content"android:layout_weight="1"android:layout_gravity="left|center_vertical"android:layout_marginRight="8dip"android:textAppearance="@style/TextAppearanceSecondaryItem" /><ImageView
                android:id="@+id/iv_alert_icon"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="center_vertical"android:background="@drawable/title_alert" /><TextView
                android:id="@+id/tv_alert_date"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="center_vertical"android:layout_marginLeft="2dip"android:layout_marginRight="8dip"android:textAppearance="@style/TextAppearanceSecondaryItem" /><ImageButton
                android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="center"android:background="@drawable/bg_btn_set_color" /></LinearLayout>
<!--正文部分:背景颜色选择(ImageView),垂直滚动条(ScrollView),字体大小设置(FrameLayout)
--><LinearLayout
            android:id="@+id/sv_note_edit"android:layout_width="fill_parent"android:layout_height="fill_parent"android:orientation="vertical"><ImageView
                android:layout_width="fill_parent"android:layout_height="7dip"android:background="@drawable/bg_color_btn_mask" /><ScrollView
                android:layout_width="fill_parent"android:layout_height="0dip"android:layout_weight="1"android:scrollbars="none"android:overScrollMode="never"android:layout_gravity="left|top"android:fadingEdgeLength="0dip"><LinearLayout
                    android:layout_width="fill_parent"android:layout_height="fill_parent"><net.micode.notes.ui.NoteEditText
                        android:id="@+id/note_edit_view"android:layout_width="fill_parent"android:layout_height="wrap_content"android:gravity="left|top"android:background="@null"android:autoLink="all"android:linksClickable="false"android:minLines="12"android:textAppearance="@style/TextAppearancePrimaryItem"android:lineSpacingMultiplier="1.2" /><LinearLayout
                        android:id="@+id/note_edit_list"android:layout_width="fill_parent"android:layout_height="wrap_content"android:orientation="vertical"android:layout_marginLeft="-10dip"android:visibility="gone" /></LinearLayout></ScrollView><ImageView
                android:layout_width="fill_parent"android:layout_height="7dip"android:background="@drawable/bg_color_btn_mask" /></LinearLayout></LinearLayout><ImageView
        android:id="@+id/btn_set_bg_color"android:layout_height="43dip"android:layout_width="wrap_content"android:background="@drawable/bg_color_btn_mask"android:layout_gravity="top|right" /><LinearLayout
        android:id="@+id/note_bg_color_selector"android:layout_width="wrap_content"android:layout_height="wrap_content"android:background="@drawable/note_edit_color_selector_panel"android:layout_marginTop="30dip"android:layout_marginRight="8dip"android:layout_gravity="top|right"<!--选择背景色为黄色--><FrameLayout
            android:layout_width="0dip"android:layout_height="match_parent"android:layout_weight="1"><ImageView
                android:id="@+id/iv_bg_yellow"android:layout_width="match_parent"android:layout_height="match_parent" /><ImageView
                android:id="@+id/iv_bg_yellow_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:layout_marginRight="5dip"android:focusable="false"android:visibility="gone"android:src="@drawable/selected" /></FrameLayout><!--选择背景色为蓝色--><FrameLayout
            android:layout_width="0dip"android:layout_height="match_parent"android:layout_weight="1"><ImageView
                android:id="@+id/iv_bg_blue"android:layout_width="match_parent"android:layout_height="match_parent" /><ImageView
                android:id="@+id/iv_bg_blue_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:layout_marginRight="3dip"android:src="@drawable/selected" /><!--选择背景色为白色--><FrameLayout
            android:layout_width="0dip"android:layout_height="match_parent"android:layout_weight="1"><ImageView
                android:id="@+id/iv_bg_white"android:layout_width="match_parent"android:layout_height="match_parent" /><ImageView
                android:id="@+id/iv_bg_white_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:layout_marginRight="2dip"android:src="@drawable/selected" /></FrameLayout><!--选择背景色为绿色--><FrameLayout
            android:layout_width="0dip"android:layout_height="match_parent"android:layout_weight="1"><ImageView
                android:id="@+id/iv_bg_green"android:layout_width="match_parent"android:layout_height="match_parent" /><ImageView
                android:id="@+id/iv_bg_green_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:src="@drawable/selected" /><!--选择背景色为红色--><FrameLayout
            android:layout_width="0dip"android:layout_height="match_parent"android:layout_weight="1"><ImageView
                android:id="@+id/iv_bg_red"android:layout_width="match_parent"android:layout_height="match_parent" /><ImageView
                android:id="@+id/iv_bg_red_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:src="@drawable/selected" /></FrameLayout></LinearLayout><!--字体大小设置--><LinearLayout
        android:id="@+id/font_size_selector"android:layout_width="fill_parent"android:layout_height="wrap_content"android:background="@drawable/font_size_selector_bg"android:layout_gravity="bottom"<!--选择小字号--><FrameLayout
            android:id="@+id/ll_font_small"android:layout_width="0dip"android:layout_height="wrap_content"android:layout_weight="1"><LinearLayout
                android:layout_width="wrap_content"android:layout_height="wrap_content"android:orientation="vertical"android:layout_gravity="center"android:gravity="center"><ImageView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:src="@drawable/font_small"android:layout_marginBottom="5dip" /><TextView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:text="@string/menu_font_small"android:textAppearance="@style/TextAppearanceUnderMenuIcon" /></LinearLayout><ImageView
                android:id="@+id/iv_small_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:layout_marginRight="6dip"android:layout_marginBottom="-7dip"android:focusable="false"android:visibility="gone"android:src="@drawable/selected" /></FrameLayout><!--选择正常字号--><FrameLayout
            android:id="@+id/ll_font_normal"android:layout_width="0dip"android:layout_height="wrap_content"android:layout_weight="1"><LinearLayout
                android:layout_width="wrap_content"android:layout_height="wrap_content"android:orientation="vertical"android:layout_gravity="center"android:gravity="center"><ImageView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:src="@drawable/font_normal"android:layout_marginBottom="5dip" /><TextView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:text="@string/menu_font_normal"android:textAppearance="@style/TextAppearanceUnderMenuIcon" /></LinearLayout><ImageView
                android:id="@+id/iv_medium_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:layout_marginRight="6dip"android:layout_marginBottom="-7dip"android:src="@drawable/selected" /><!--选择大字号--><FrameLayout
            android:id="@+id/ll_font_large"android:layout_width="0dip"android:layout_height="wrap_content"android:layout_weight="1"><LinearLayout
                android:layout_width="wrap_content"android:layout_height="wrap_content"android:orientation="vertical"android:layout_gravity="center"android:gravity="center"><ImageView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:src="@drawable/font_large"android:layout_marginBottom="5dip" /><TextView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:text="@string/menu_font_large"android:textAppearance="@style/TextAppearanceUnderMenuIcon" /></LinearLayout><ImageView
                android:id="@+id/iv_large_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:layout_marginRight="6dip"android:layout_marginBottom="-7dip"android:src="@drawable/selected" /></FrameLayout><!--选择超大字号--><FrameLayout
            android:id="@+id/ll_font_super"android:layout_width="0dip"android:layout_height="wrap_content"android:layout_weight="1"><LinearLayout
                android:layout_width="wrap_content"android:layout_height="wrap_content"android:orientation="vertical"android:layout_gravity="center"android:gravity="center"><ImageView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:src="@drawable/font_super"android:layout_marginBottom="5dip" /><TextView
                    android:layout_width="wrap_content"android:layout_height="wrap_content"android:text="@string/menu_font_super"android:textAppearance="@style/TextAppearanceUnderMenuIcon" /></LinearLayout><ImageView
                android:id="@+id/iv_super_select"android:layout_width="wrap_content"android:layout_height="wrap_content"android:layout_gravity="bottom|right"android:focusable="false"android:visibility="gone"android:layout_marginRight="6dip"android:layout_marginBottom="-7dip"android:src="@drawable/selected" /></FrameLayout></LinearLayout>
</FrameLayout>

    说明:希望通过blog来记录我的学习历程,同时想借助此平台分享遇到的各种问题以及解决方案,期待能够与大家共同进步,Nothing is waived.

Android布局——小米便签编辑界面xml相关推荐

  1. 在Android Studio下配置小米便签

    在Android Studio下配置小米便签 Android studio2022的下载与安装 在官网下载最新安装包Download Android Studio & App Tools - ...

  2. 小米便签维护过程记录——可能出现问题解决方案

    在对小米便签开源代码进行研究和维护及新功能开发的同时,会遇到很多问题,将以本文进行记录总结. 导入项目 若不导入直接Open会导致默认为Project,不为Android. 小米标签菜单栏不显示的问题 ...

  3. 小米便签开源项目本地环境搭建

    基于Android Studio.和Gradle 的小米便签配置和安装 一.Android Studio的中文社区(官网)下载最新的Android Studio 点击开始传送http://www.an ...

  4. android开发实例便签,Android便签应用

    [实例简介] 一个简单实用的基于Android的便签小应用,界面美观,功能实用,几乎可以媲美商业小应用了,欢迎朋友下载体验或使用,有什么建议和批评,欢迎留言,谢谢合作! [实例截图] [核心代码] 便 ...

  5. 小米便签从0到1维护教程

    小米便签开源社区版从0到1维护教程 1.前置条件-------软件的安装: 开发工具:Android studio 下载Android studio 汉化教程 安装请自行解决 SDK版本以及相关文件 ...

  6. 浅易便签-主界面汉堡菜单等部分

    浅易便签-主界面汉堡菜单等部分 一.用例分析 功能主题:在主界面创建汉堡菜单,供用户选择.浏览便签,在汉堡菜单的SplitView.content中为便签页面,供用户编辑便签或使用其他功能 角色:用户 ...

  7. Android 开发资料便签

    Android 开发资料便签 标签:Android 本文Github链接地址 本文CSDN链接地址 本文MD版本阅读链接地址 平台 控制   [阿里] [百度] [友盟] [微信] [腾讯] [微博] ...

  8. Android 开发资料便签 1

    版权声明:本文为博主原创文章,未经博主允许不得转载. https://blog.csdn.net/qingfeng812/article/details/72519270 Android 开发资料便签 ...

  9. 在Win10以及SDK为33的环境下——小米便签项目的搭建

    文章目录 0. 我的操作系统和开发环境 1. 相关文件下载: 2. import project: 2.1 用import project导入项目 3. make project: 3.1 AS中的命 ...

  10. 便签图片存储Android,安卓手机便签以图片形式分享是怎么实现的?

    原标题:安卓手机便签以图片形式分享是怎么实现的? 有不少网友表示自己都是比较喜欢在手机便签中记录一些生活灵感.随笔感想之类的,有的人还会把遇到的一些好句.好文章记录到便签中.不过当有的网友想要把某条便 ...

最新文章

  1. TinyOS下TOSSIM仿真
  2. vsftp配置文件详解
  3. 语言解析ssl包_HPSocket v5.0.1:支持 IPv6 及多 SSL 证书
  4. layui表单mysql_layui表单验证支持select下拉框的一种方法
  5. [html] 如何更改浏览器左上角标题旁的图标?
  6. linux下的gpio转串口驱动,X-026-KERNEL-Linux gpio driver的移植之gpio range
  7. python获取pc微信好友列表_python使用itchat获取微信好友列表
  8. vvv在线文档导出工具_使用ApiPost工具快速生成在线接口文档
  9. 汇总10.4版本ArcGIS Server与ArcMap 安装+SDE+注册数据源(非破解)
  10. 【BZOJ3992】【SDOI2015】序列统计
  11. 企业如何高效用云?| 资深运维架构师细说云架构下的运维体系构建
  12. Hadoop教程(一) Hadoop入门教程
  13. win11官网的预览版系统如何下载安装
  14. 经过路由无法找到计算机,共享打印机找不到对方电脑解决方法
  15. java 获得pdf 目录的方法
  16. 滴滴打车CTO张博:下一阶段重点机器学习
  17. Nonebot QQ机器人插件八:点歌(网易云音乐)
  18. 不做律师,玩起了电子合同,这家入选微软加速器第十期的电子合同企业究竟是什么来头?
  19. 读书笔记 - 《经济学通识》
  20. JavaScript对象的声明及操作

热门文章

  1. 雨林木风四大绝笔系统下载
  2. dell笔记本电脑驱动_2020年最佳笔记本电脑top榜
  3. PTA 数据结构与算法题目集(中文) 7-49 打印学生选课清单 (25分)题解
  4. 时间序列数据的平稳性检验
  5. 给potplayer配置iptv源,看所有你想看的电视
  6. excel使用教程_有哪些超好用、高质量的Excel学习网站?
  7. python实现钉钉群自动警报
  8. Xcode 模拟器Simulator手动下载(iOS 8 - iOS 12)
  9. 浅谈WPF中的Calendar日历控件
  10. winform日历控件