Coder Social home page Coder Social logo

Comments (5)

ISchwarz23 avatar ISchwarz23 commented on July 18, 2024

Hi @rubin-parakhi

I'm not sure, if I understood corectly what you are trying to achive. You try do display column headers in your table by using the SimpleTableHeaderAdapter, right?

Best regards,
Ingo

from sortabletableview.

joemackay avatar joemackay commented on July 18, 2024

Is it possible to place other views such as TextViews etc next to the TableView or does it command ownership of the screen like a ListView does. My Relative layout has a TextView at the top and Tableview right after it. Now the tableView has a very long list and cannot scroll.

`
<RelativeLayout

android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.xxx.app.xxx.src.CourseDetailsFragment"
android:background="@color/body_readable_bg"
android:id="@+id/course_details_">
<TextView
        android:id="@+id/course_title"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:textAppearance="?attr/textAppearanceListItem"
        android:textSize="16sp"
        android:textStyle="bold"
        android:layout_marginTop="10dp"/>

<LinearLayout
    android:id="@+id/instTableView_cont"
    android:orientation="horizontal"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:layout_centerHorizontal="true"
    android:layout_marginTop="10dip"
    android:layout_alignParentLeft="true"
    android:layout_below="@id/course_title"
    android:background="@drawable/flat_border_set"
    android:gravity="center_horizontal">

    <de.codecrafters.tableview.TableView
        xmlns:table="http://schemas.android.com/apk/res-auto"
        android:id="@+id/instTableView"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:divider="@color/list_divider"
        android:dividerHeight="1dip"
        android:textSize="@dimen/ten_dp" />
</LinearLayout>

</

RelativeLayout>
`

Joe

from sortabletableview.

ISchwarz23 avatar ISchwarz23 commented on July 18, 2024

Hi @joemackay,

for the next time, please create a seperate issue for your questions.
In your case the issue is in the layout file. Your LinearLayout and TableView have the height wrap_content, so they will grow to wrap the complete tableview data content. This is why the tableview is very long and there is no scrolling. I would get comletely rid of your linear layout and do it like this:

<RelativeLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="com.xxx.app.xxx.src.CourseDetailsFragment"
    android:background="@color/body_readable_bg"
    android:id="@+id/course_details">

    <TextView
        android:id="@+id/course_title"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:textAppearance="?attr/textAppearanceListItem"
        android:textSize="16sp"
        android:textStyle="bold"
        android:layout_marginTop="10dp"/>

    <de.codecrafters.tableview.TableView
        xmlns:table="http://schemas.android.com/apk/res-auto"
        android:id="@+id/instTableView"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_below="@id/course_title"
        android:layout_marginTop="10dp"
        android:divider="@color/list_divider"
        android:dividerHeight="1dp"
        android:textSize="@dimen/ten_dp" />

</RelativeLayout>

from sortabletableview.

rubin-parakhi avatar rubin-parakhi commented on July 18, 2024

Hi there,
I used your library and tried to implement the table but couldn't display
the header section using tableadapter. No way to add header like in
sortable adapter
On Jul 11, 2016 10:09 PM, "Ingo Schwarz" [email protected] wrote:

Hi @rubin-parakhi https://github.com/rubin-parakhi

I'm not sure, if I understood corectly what you are trying to achive. You
try do display column headers in your table by using the
SimoleTableHeaderAdapter?

Best regards,
Ingo


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#40 (comment),
or mute the thread
https://github.com/notifications/unsubscribe/AMiUGz5gdmZB9ih5NH611s14hW7zuOU9ks5qUm5EgaJpZM4JJTjt
.

from sortabletableview.

ISchwarz23 avatar ISchwarz23 commented on July 18, 2024

Did you have a look to the sample application? If yes and it is still not working I can only help you, if you share your code.

from sortabletableview.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.