Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    How to Develop a Calendar Widget.

    Mobile and Embedded
    11
    119
    57193
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • I
      imrrk last edited by A Former User

      Hello Friends,I want to develop a full fledged calendar, so that i can interact with the dates, set reminders on specified date, One idea, in my mind is, to take separate buttons for all the dates, but if do like that what about the default calendar widget already present in the qt designer, can't we use that directly... please help me out..

      Regards
      imrrk

      1 Reply Last reply Reply Quote 0
      • A
        andre last edited by

        That is not a simple challenge. You can look at the way the calendar widget is implemented for inspiration. You will have to do lots of rendering of your own. You can use any of the tree approaches Qt offers for that: rendering widgets with QPaintEvent, using QGraphicsView items or even using QML.

        1 Reply Last reply Reply Quote 0
        • G
          giesbert last edited by

          You can have a look at "qt-apps.org":http://qt-apps.org/content/show.php/running?content=91023 there are some implementations of calendars.

          I'm sure there are more (perhaps in KDE, or some commercial solutions).

          Nokia Certified Qt Specialist.
          Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

          1 Reply Last reply Reply Quote 0
          • K
            kamalakshantv last edited by

            Using QML for UI will be much better I think, but then this will limit your application for 5th Edition devices and above only.

            1 Reply Last reply Reply Quote 0
            • I
              imrrk last edited by

              ok andre,my problem is that,i want to call some functions when a user clicks on the specified date..suppose a calendar is displaying a month of april,then when i select a specified date,i want to set some appointments or some remnders,how to do that..

              1 Reply Last reply Reply Quote 0
              • I
                imrrk last edited by

                Hello Qtk,I want to interact with the dates

                1 Reply Last reply Reply Quote 0
                • G
                  giesbert last edited by

                  Did you look at the examples at qt-apps?
                  They have a full featured calender app, so they also handle clicks.
                  If you implement it with model/view and also have a custom view, you can handle clicks.

                  where is the problem?

                  Nokia Certified Qt Specialist.
                  Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

                  1 Reply Last reply Reply Quote 0
                  • I
                    imrrk last edited by

                    hi gerolf,can specify which example to look at..because i found many

                    1 Reply Last reply Reply Quote 0
                    • I
                      imrrk last edited by

                      hey gerolf,i m not getting you...

                      1 Reply Last reply Reply Quote 0
                      • A
                        andre last edited by

                        imrrk: this is not a chat channel. Please use the edit link to the right of each message to add to a message; don't just post new ones all the time.

                        On topic: I found that good calendar examples are hard to come by. I found a nice one (via a tip earlier in this forum, search the forum for calendar and you will find the topic), but that one I ended up getting send directly from the author. I have not seen it published in the open again yet.

                        1 Reply Last reply Reply Quote 0
                        • G
                          giesbert last edited by

                          The link I provided was one app at qt-apps. But if you find more, have a look at them, if they look like what yu need, look at the source.

                          Nokia Certified Qt Specialist.
                          Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

                          1 Reply Last reply Reply Quote 0
                          • F
                            frankcyblogic.de last edited by

                            I just recently create a minimal calendar in QtQuick in Javascript. It is unfinished, but shows dates correctly;)

                            https://github.com/unclefrank/weekly

                            1 Reply Last reply Reply Quote 0
                            • I
                              imrrk last edited by

                              hi gerolf,I got about the application you are speaking about,,is it applicable to mobile phones..also

                              1 Reply Last reply Reply Quote 0
                              • A
                                andre last edited by

                                [quote author="imrrk" date="1302167524"]hi gerolf,I got about the application you are speaking about,,is it applicable to mobile phones..also

                                [/quote]
                                Try and see?

                                1 Reply Last reply Reply Quote 0
                                • I
                                  imrrk last edited by

                                  Thanks andre...

                                  1 Reply Last reply Reply Quote 0
                                  • I
                                    imrrk last edited by

                                    hello friends,still i dint get any concrete material so that i can develop a calendar for mobile..actually i want to use pushbuttons,for dates i.e very date is on pushbutton..so that i can click this button and i can add some notes for that button...but with the inbuilt widget its not possible i guess,because they have used QTableformat class and divided it into rows and columns..so friends please help me out..

                                    regards
                                    imrrk

                                    1 Reply Last reply Reply Quote 0
                                    • G
                                      giesbert last edited by

                                      If you have no existing code that works for you, start build it on your own. I have never seen a calendar build on buttons.

                                      We can give you ideas, suggestions for specific technical stuff. But we don't write your code. If you want it with buttons, sit down, take QtCreator and start coding.

                                      Nokia Certified Qt Specialist.
                                      Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

                                      1 Reply Last reply Reply Quote 0
                                      • I
                                        imrrk last edited by

                                        but gerolf i just need the correct direction,have u seen the calendar of nokia phones..it has that feature...

                                        1 Reply Last reply Reply Quote 0
                                        • A
                                          andre last edited by

                                          First: why do you think you need buttons? You can of course implement a calendar based on grid of buttons. I am just wondering how that would help you achieve your goals?

                                          1 Reply Last reply Reply Quote 0
                                          • G
                                            giesbert last edited by

                                            That you click on a button?
                                            Or that you click on a date and something happens?

                                            You can use a model/view (like Qt calendar widget) and react on the mouse events. No buttons needed. Qt has no build in "button calendar". and if you need one, build it. Or try if you can get the code for the nokia phone calendar.

                                            Nokia Certified Qt Specialist.
                                            Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post