Since InfoCard is a component within the QtChatKit repository, you cannot clone only this folder with a simple git command. Here are the two best ways to add it to your Qt project:
This is the simplest way to get started.
- Download the two essential files:
- Add both files directly to your Qt project's source directory.
- If using qmake (.pro file): Add them to your
.profile:HEADERS += InfoCard.h SOURCES += InfoCard.cpp
- If using CMake: Add them to your
CMakeLists.txt:add_executable(YourApp main.cpp mainwindow.cpp InfoCard.cpp # Add this mainwindow.h InfoCard.h # Add this )
- Now you can
#include "InfoCard.h"in your code and use it.
This method clones the entire repository, and you just copy the folder you need.
- Clone the full repository:
git clone [https://github.com/Amin4424/QtChatKit.git](https://github.com/Amin4424/QtChatKit.git)
- Navigate to the
QtChatKit/InfoCarddirectory. - Copy the
InfoCard.handInfoCard.cppfiles from this folder into your own project. - Follow steps 3-5 from Method 1 to add them to your build system.
Please note: QtChatKit is currently under active development.
The repository structure is evolving, and it does not yet have a unified library format. New components, animations, and features will be added regularly.
از آنجایی که InfoCard یک کامپوننت در داخل ریپازیتوری QtChatKit است، شما نمیتوانید فقط این پوشه را با یک دستور ساده git کلون کنید. در اینجا دو روش عالی برای افزودن آن به پروژه Qt شما آمده است:
این سادهترین راه برای شروع است.
- این دو فایل ضروری را دانلود کنید:
- هر دو فایل را مستقیماً به پوشه سورس پروژه Qt خود اضافه کنید.
- اگر از qmake (.pro) استفاده میکنید: آنها را به فایل
.proخود اضافه کنید:HEADERS += InfoCard.h SOURCES += InfoCard.cpp
- اگر از CMake استفاده میکنید: آنها را به
CMakeLists.txtخود اضافه کنید:add_executable(YourApp main.cpp mainwindow.cpp InfoCard.cpp # این را اضافه کنید mainwindow.h InfoCard.h # این را اضافه کنید )
- اکنون میتوانید فایل
InfoCard.hرا در کد خود#includeکرده و از آن استفاده کنید.
در این روش کل ریپازیتوری کلون میشود و شما فایلهای مورد نیاز را کپی میکنید.
- کل ریپازیتوری را کلون کنید:
git clone [https://github.com/Amin4424/QtChatKit.git](https://github.com/Amin4424/QtChatKit.git)
- به پوشه
QtChatKit/InfoCardبروید. - فایلهای
InfoCard.hوInfoCard.cppرا از این پوشه در پروژه خود کپی کنید. - مراحل ۳ تا ۵ از روش ۱ را دنبال کنید تا آنها را به سیستم بیلد خود اضافه کنید.
لطفاً توجه داشته باشید: QtChatKit در حال حاضر در مرحله توسعه فعال قرار دارد.
ساختار ریپازیتوری در حال تکامل است و هنوز به یک فرمت کتابخانهای یکپارچه نرسیده است. کامپوننتهای جدید، انیمیشنها و قابلیتهای تازه بهطور منظم به آن اضافه خواهند شد.