
671 N.W.2d 758 (2003)
267 Neb. 18
William E. GAST, Appellant,
v.
Paul F. PETERS and Gast & Peters, a Nebraska partnership, Appellees.
No. S-02-974.
Supreme Court of Nebraska.
November 21, 2003.
*760 David E. Pavel, of David E. Pavel Law Offices, P.C., Omaha, for appellant.
Monte Taylor and Paul F. Peters, of Taylor, Peters & Drews, Omaha, for appellees.
HENDRY, C.J., and WRIGHT, CONNOLLY, GERRARD, STEPHAN, McCORMACK, and MILLER-LERMAN, JJ.
STEPHAN, J.
This appeal arises from a dispute between two lawyers involving fees earned before the dissolution of their partnership but collected thereafter. Following a bench trial, the district court for Douglas County found that Paul F. Peters was justified in setting off $17,620.62 from fees due his former partner, William E. Gast, from a case which Peters had concluded because Gast had underpaid Peters by that same amount in distributing fees collected on another case which Gast had concluded. Upon consideration of Gast's appeal, we find no error and affirm.

BACKGROUND
The parties entered into a written partnership agreement effective January 1, 1990, in which they agreed to practice law under the firm name "Gast & Peters" (G&P). Under the terms of the agreement, the net profits and losses of the partnership were to be divided and borne equally between the partners.
In a November 10, 1992, agreement (merger agreement), Gast and Peters each indicated their acceptance of the outlined terms and conditions of a merger between G&P and the law firm of Schmid, Mooney & Frederick, P.C. (SM&F), effective January 1, 1993. Paragraph 4 of the merger agreement provided in relevant part:
As of January 1, 1993, all contingent fee cases will be valued by G&P and SM&F, i.e., each pending case would be individually reviewed. Work completed and work to be performed would be apportioned on a percentage basis on each case. At the time of eventual payment of fees, the fees from each case would then be apportioned accordingly between G&P and SM&F, i.e., fees from a case 10% completed as of time of merger would be apportioned 10% to G&P and 90% to SM&F.
The merger agreement made specific reference to an attached letter dated October 23, 1992, signed by Peters on behalf of G&P and Keith I. Frederick on behalf of SM&F. This letter listed G&P's 14 largest pending contingency cases and assigned fee apportionment percentages to G&P and SM&F based on work which G&P had completed on each case as of the *761 date of the letter. The letter provided that the proportions of the fees would become "vested" in G&P and SM&F, respectively, as of the January 1, 1993, merger date, subject to any adjustments required because of significant additional work accomplished prior to the merger.
From January 1, 1993, until February 28, 1996, both Gast and Peters were shareholders, directors, and employees of SM&F. Both parties left SM&F on approximately March 1, 1996, and thereafter have practiced law separately from each other. When Gast and Peters left SM&F, all but 2 of the 14 contingent fee cases referred to in the merger documents had been concluded. The two unresolved cases are referred to by the parties as the "Yager" and "Stenson" cases.
Gast originated the Yager case for G&P in 1990. When G&P merged with SM&F, G&P withdrew its representation of the client. Gast and attorney Terry Gutierrez continued working on the case as employees of SM&F. When Gast left SM&F, he took the Yager files with him, and he and his new firm, Gast, Ratz & Gutierrez, P.C. (SR&G), assumed responsibility for the case until its settlement in 1997. There is no record of the client's ever dismissing G&P or entering into a contingency fee agreement with SM&F or SR&G. As a result of the settlement, a total of $97,892.32 in attorney fees was received and deposited in the SR&G trust account. Pursuant to the merger agreement, the fees from the Yager case were to be apportioned 60 percent to G&P and 40 percent to SM&F. Under this formula, G&P would have received $58,735.39. On February 7, 1998, after receipt of the Yager fee, Gast and other members of SR&G met with Peters and Frederick to discuss apportionment of the fee. Both prior to and during this meeting, Peters stated his position that G&P was entitled to 60 percent of the fee pursuant to the merger agreement. Gast and his SR&G colleagues took the position that the remaining 40 percent would be insufficient to compensate both SM&F and SR&G. No agreement was reached on this point, and Peters left the meeting. Subsequently, Gast and the members of SR&G decided to disburse 24 percent of the Yager fee in the amount of $23,494.16 to G&P, with a portion of the balance distributed to SM&F and the remainder retained by SR&G.
Peters originated the Stenson case for G&P. Peters retained the Stenson case files when he left SM&F, and both he and Gast were involved with the case until its conclusion by settlement in 1997. Pursuant to the merger agreement, fees from the Stenson case were to be apportioned 85 percent to G&P and 15 percent to SM&F. In January 1997, however, Peters entered into an agreement on behalf of G&P to modify the Stenson fee apportionment agreement due to the amount of work which he and Gast performed subsequent to their departure from SM&F. Under the modified agreement, G&P's percentage was increased from 85 percent to 88.75 percent and SM&F's share was reduced from 15 percent to 11.25 percent. Accordingly, G&P received 88.75 percent of the total attorney fees in the Stenson case, or $74,032.29. SM&F issued a check payable to G&P for this amount from its trust account and delivered it to Peters. Peters deposited the check into a newly created G&P account. In a letter dated September 11, 1998, Peters informed Gast of the deposit. In the same letter, Peters provided a detailed account of the manner in which he was disbursing the deposited funds. He informed Gast that he was disbursing 50 percent of the total proceeds, or $37,016.15, to himself in accordance with the G&P partnership agreement. Peters further disclosed that out of Gast's equal share, he was withholding the *762 $17,620.62 in fees which he claimed to have been underpaid on the Yager settlement, thereby resulting in a net payment to Gast in the amount of $19,395.53.
Gast filed this action in which he sought a declaratory judgment that he was entitled to an additional $17,620.62 from the fee generated by the Stenson settlement. In his answer, Peters affirmatively alleged that the amount paid to Gast in the Stenson case constituted Gast's full 50-percent share minus a legal and proper setoff for Peters for the unpaid portion of Peters' claimed share of the Yager fees. Both Gast and Peters filed motions for summary judgment. Following two interlocutory orders which resulted in an entry of partial summary judgment for each party, the district court conducted a bench trial and thereafter concluded that Peters had properly set off the disputed $17,620.62, to which he was entitled. Gast filed this timely appeal, which we moved to our docket on our own motion pursuant to our authority to regulate the caseloads of the appellate courts of this state. See Neb.Rev.Stat. § 24-1106(3) (Reissue 1995).

ASSIGNMENT OF ERROR
Gast assigns, restated and consolidated, that the trial court erred in finding that Peters properly set off $17,620.62 from the Stenson settlement.

STANDARD OF REVIEW
An action for declaratory judgment is sui generis; whether such action is to be treated as one at law or one in equity is to be determined by the nature of the dispute. Mason v. City of Lincoln, 266 Neb. 399, 665 N.W.2d 600 (2003); Spanish Oaks v. Hy-Vee, 265 Neb. 133, 655 N.W.2d 390 (2003); Lake Arrowhead, Inc. v. Jolliffe, 263 Neb. 354, 639 N.W.2d 905 (2002).
An action for the dissolution of a partnership and an accounting between partners is one in equity and is reviewed in this court de novo on the record. Bass v. Dalton, 213 Neb. 360, 329 N.W.2d 115 (1983).
In reviewing an equity action for a declaratory judgment, an appellate court tries factual issues de novo on the record and reaches a conclusion independent of the findings of the trial court, subject to the rule that where credible evidence is in conflict on material issues of fact, the reviewing court may consider and give weight to the fact that the trial court observed the witnesses and accepted one version of the facts over another. Lake Arrowhead, Inc. v. Jolliffe, supra.

ANALYSIS
As this is essentially an action for an accounting between partners of a partnership formed prior to January 1, 1998, the Uniform Partnership Act (UPA), Neb.Rev.Stat. §§ 67-301 to 67-346 (Reissue 1996), is applicable and determines the rights and duties of the parties. See § 67-318. It is undisputed that Gast and Peters were equal partners in G&P and that pursuant to their partnership agreement, each was entitled to one half of the partnership's profits. The merger between G&P and SM&F resulted in the dissolution of G&P. See § 67-329 (defining dissolution of partnership as "the change in the relation of the partners caused by any partner ceasing to be associated in the carrying on as distinguished from the winding up of the business"). Dissolution of a partnership, however, is not synonymous with its termination. "On dissolution the partnership is not terminated but continues until the winding up of partnership affairs is completed." § 67-330. Accord Essay v. Essay, 175 Neb. 689, 123 N.W.2d 20 (1963). The collection *763 and distribution of the contingent fees in the Yager and Stenson cases were part of the winding up of the affairs of G&P. Thus, while the merger of the two firms marked the end of the operations of G&P, it did not result in the complete winding up of its affairs.
Because a partnership terminates only when the business of the partnership has been wound up, whatever rules apply with regard to distribution before the partnership is dissolved apply after it is dissolved but before it is terminated by the winding up of its affairs. Smith v. Daub, 219 Neb. 698, 365 N.W.2d 816 (1985). Here, it is undisputed that each party was entitled to 50 percent of the fees received by G&P. Indeed, Gast's entire claim is that he is entitled to a full 50 percent of the G&P fee in the Stenson case and that Peters improperly withheld $17,620.62 from that share. Likewise, Peters claims that he is entitled to 50 percent of G&P's fee in the Yager case. The dispute centers upon the amount of that fee, which Peters contends Gast understated by $35,241.23, thereby depriving Peters of $17,620.62, his 50-percent share of that amount.
At the time of the G&P merger with SM&F, it was agreed by all parties that G&P would receive 60 percent of the eventual fee collected in the Yager case based upon work which its lawyers had completed prior to the merger. It is undisputed that Gast subsequently caused $23,494.16, representing approximately 24 percent of the Yager fee, to be disbursed to G&P, with the balance paid to SM&F and Gast's new firm, SR&G. In his operative amended petition and testimony at trial, Gast claimed that the reduction was justified because the percentage of each fee payable to G&P as set forth in the merger agreement was only applicable "in the event such cases were concluded during the merger." However, we find no language in the merger agreement which would support this position.
When the terms of a contract are clear, a court may not resort to rules of construction, and the terms are to be accorded their plain and ordinary meaning as the ordinary or reasonable person would understand them. Farm Bureau Ins. Co. v. Martinsen, 265 Neb. 770, 659 N.W.2d 823 (2003). A court is not free to rewrite a contract or to speculate as to terms of the contract which the parties have not seen fit to include. Kropp v. Grand Island Pub. Sch. Dist. No. 2, 246 Neb. 138, 517 N.W.2d 113 (1994).
The letter attached to the merger agreement set forth G&P's 14 largest pending contingency cases and assigned the percentage of any eventual fees which would be allocated to G&P based upon the amount of work it had completed on each case prior to the merger, with the balance payable to SM&F. The letter specifically provided that the assigned percentages of the fees would become "vested" in G&P and SM&F, respectively, as of the January 1, 1993, merger date. The letter also provided for the contingency that "[s]ettlement agreements may be reached in some of the 14 cases prior to the effective date of the merger, and such cases would not become subject to fee-apportionment between G&P and SM&F." The agreement did not address the possibility of settlement agreements which might be reached after Gast and Peters had left SM&F. Rather, it unambiguously and unconditionally provided that as of the merger date, G&P had done 60 percent of the work necessary to conclude the Yager case, for which it would receive 60 percent of any eventual fee paid after the merger, and that SM&F would be entitled to the remaining 40 percent. We find Gast's claim that the agreement was in effect only for *764 the duration of the merger to be without merit.
Gast argues in the alternative that the original agreement was replaced at the time of his departure from SM&F when he and Frederick came to an understanding that when each file was finished, they would sit down and discuss "`what was fair between [Gast] after he left and [SM&F] before he left.'" Reply brief for appellant at 22. Gast argues that SM&F had the sole discretion to enter into an agreement regarding the Yager case and that "the only claim of the dissolved G&P to Yager case fees was derivative of SMF, which succeeded to G&P's former powers and privileges with respect to the case on account of the SMF/G&P Merger." Id. at 29. This argument is without merit.
As noted above, although the merger brought about the dissolution of G&P, it did not wind up the partnership's affairs. The winding up could be completed only when G&P's share of the contingent fees pending at the time of merger was received and disbursed to the partners. During this winding up period, both Gast and Peters were bound by the statutory rule that
[e]very partner must account to the partnership for any benefit, and hold as trustee for it any profits derived by him without the consent of the other partners from any transaction connected with the formation, conduct, or liquidation of the partnership or from any use by him of its property.
§ 67-321(1). With respect to this fiduciary duty, we have held that partners must deal frankly and honestly with one another and that as trustees, they cannot derive a secret profit from partnership transactions unknown to the other. Bode v. Prettyman, 149 Neb. 179, 30 N.W.2d 627 (1948). We held in Schrempp and Salerno v. Gross, 247 Neb. 685, 529 N.W.2d 764 (1995), that a lawyer who withdrew from a partnership in a manner which caused its dissolution had a continuing fiduciary duty that prohibited him from entering into contracts for personal gain in connection with unfinished business of the partnership. We further held that absent a contrary agreement, any income generated through the winding up of unfinished business of a partnership is allocated to the former partners according to their respective interests in the partnership.
Under these principles, Gast owed a fiduciary duty to Peters and G&P with respect to the 60-percent share of the Yager fee allocated to G&P in the merger documents. This duty precluded him from entering into any agreement to decrease G&P's percentage without Peters' consent. By reducing G&P's share of the Yager fee from 60 percent to 24 percent so that his new firm could receive a portion of the fee, Gast violated the fiduciary duty which he owed to Peters in the winding up of G&P's affairs. As a consequence, Peters received $17,620.62 less than his entitlement from the Yager fee, and the district court therefore correctly determined that Peters was justified in setting off and deducting that amount from Gast's share of the Stenson fee.
For the sake of completeness, we note our disagreement with Gast's contention that the final judgment of the district court is inconsistent with its prior orders. In its first order, the district court denied Peters' motion for summary judgment and granted that of Gast, awarding Gast damages in the amount of $17,620.62. In its subsequent modification of that order, the district court awarded both parties "summary judgment on the issue of liability" and denied both parties' motions on the issue of damages. Taken together, we interpret these orders as an interlocutory determination that the parties were subject *765 to the terms of their partnership agreement, and therefore each party was entitled to 50 percent of the fees received by G&P. That is entirely consistent with the final determination by the district court that G&P should have received its full 60-percent share of the fee paid in the Yager case, in accordance with the merger documents, and that Peters was entitled to receive 50 percent of that amount.

CONCLUSION
For the foregoing reasons, we conclude that the district court did not err in determining that Peters was entitled to set off and retain $17,620.62 from Gast's share of the Stenson fee as compensation for the underpayment of Peters' rightful share of the Yager fee. We therefore affirm the judgment of the district court.
AFFIRMED.
